Make DebugSession.name writable; fixes #79583

This commit is contained in:
Dmitry Gozman
2019-08-29 17:23:16 -07:00
parent 7e5adb5dae
commit cb6b17d6f3
10 changed files with 82 additions and 17 deletions

View File

@@ -687,6 +687,13 @@ export class ExtHostDebugService implements IExtHostDebugService, ExtHostDebugSe
this._onDidChangeActiveDebugSession.fire(this._activeDebugSession);
}
public async $acceptDebugSessionNameChanged(sessionDto: IDebugSessionDto, name: string): Promise<void> {
const session = await this.getSession(sessionDto);
if (session) {
session._acceptNameChanged(name);
}
}
public async $acceptDebugSessionCustomEvent(sessionDto: IDebugSessionDto, event: any): Promise<void> {
const session = await this.getSession(sessionDto);
const ee: vscode.DebugSessionCustomEvent = {
@@ -917,6 +924,15 @@ export class ExtHostDebugSession implements vscode.DebugSession {
return this._name;
}
public set name(name: string) {
this._name = name;
this._debugServiceProxy.$setDebugSessionName(this._id, name);
}
_acceptNameChanged(name: string) {
this._name = name;
}
public get workspaceFolder(): vscode.WorkspaceFolder | undefined {
return this._workspaceFolder;
}