Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 5d5ecdc

Browse files
Merge pull request #3308 from code-asher/pty-host-service
2 parents 65c2510 + bdb230b commit 5d5ecdc

File tree

5 files changed

+80
-338
lines changed

5 files changed

+80
-338
lines changed

‎lib/vscode/coder.js‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,14 @@ const vscodeEntryPoints = _.flatten([
1414
buildfile.workerExtensionHost,
1515
buildfile.workerNotebook,
1616
buildfile.keyboardMaps,
17+
// See ./src/vs/workbench/buildfile.desktop.js
1718
buildfile.entrypoint("vs/platform/files/node/watcher/unix/watcherApp"),
1819
buildfile.entrypoint("vs/platform/files/node/watcher/nsfw/watcherApp"),
20+
buildfile.entrypoint('vs/platform/terminal/node/ptyHostMain'),
1921
buildfile.entrypoint("vs/workbench/services/extensions/node/extensionHostProcess"),
2022
]);
2123

24+
// See ./build/gulpfile.vscode.js
2225
const vscodeResources = [
2326
"out-build/vs/server/fork.js",
2427
"!out-build/vs/server/doc/**",

‎lib/vscode/src/vs/platform/terminal/node/ptyService.ts‎

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -79,10 +79,7 @@ export class PtyService extends Disposable implements IPtyService {
7979
throw new Error('Attempt to create a process when attach object was provided');
8080
}
8181
const id = ++this._lastPtyId;
82-
/**
83-
* NOTE@coder: pass ID into TerminalProcess to fix compile.
84-
*/
85-
const process = new TerminalProcess(id, shellLaunchConfig, cwd, cols, rows, env, executableEnv, windowsEnableConpty, this._logService);
82+
const process = new TerminalProcess(shellLaunchConfig, cwd, cols, rows, env, executableEnv, windowsEnableConpty, this._logService);
8683
process.onProcessData(event => this._onProcessData.fire({ id, event }));
8784
process.onProcessExit(event => this._onProcessExit.fire({ id, event }));
8885
if (process.onProcessOverrideDimensions) {

‎lib/vscode/src/vs/platform/terminal/node/terminalProcess.ts‎

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -68,21 +68,16 @@ interface IWriteObject {
6868
}
6969

7070
export class TerminalProcess extends Disposable implements ITerminalChildProcess {
71+
readonly id = 0;
7172
readonly shouldPersist = false;
7273

7374
private static _lastKillOrStart = 0;
7475

7576
private _exitCode: number | undefined;
7677
private _exitMessage: string | undefined;
7778
private _closeTimeout: any;
78-
/**
79-
* NOTE@coder: set _ptyProcess and _currentTitle to protected
80-
* to allow access from subclasses.
81-
*
82-
* We subclass it in src/vs/server/channel.ts
83-
*/
84-
protected _ptyProcess: pty.IPty | undefined;
85-
protected _currentTitle: string = '';
79+
private _ptyProcess: pty.IPty | undefined;
80+
private _currentTitle: string = '';
8681
private _processStartupComplete: Promise<void> | undefined;
8782
private _isDisposed: boolean = false;
8883
private _windowsShellHelper: WindowsShellHelper | undefined;
@@ -111,9 +106,7 @@ export class TerminalProcess extends Disposable implements ITerminalChildProcess
111106
private readonly _onProcessShellTypeChanged = this._register(new Emitter<TerminalShellType>());
112107
public readonly onProcessShellTypeChanged = this._onProcessShellTypeChanged.event;
113108

114-
// NOTE@coder: add id to constructor
115109
constructor(
116-
public readonly id: number = 0,
117110
private readonly _shellLaunchConfig: IShellLaunchConfig,
118111
cwd: string,
119112
cols: number,

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /