diff --git a/src/vs/workbench/parts/debug/electron-browser/variablesView.ts b/src/vs/workbench/parts/debug/electron-browser/variablesView.ts index b22db68a531c0224a19a1a28a38aef94a016157b..62271136f011b6838e54b8a39dc2befbcc0d25d4 100644 --- a/src/vs/workbench/parts/debug/electron-browser/variablesView.ts +++ b/src/vs/workbench/parts/debug/electron-browser/variablesView.ts @@ -32,9 +32,6 @@ import { onUnexpectedError } from 'vs/base/common/errors'; const $ = dom.$; -// TODO@Isidor Remember expanded elements when there are some (otherwise don't override/erase the previous ones) -// Just give the identity provider to the tree and that should solve it - export const variableSetEmitter = new Emitter(); export class VariablesView extends ViewletPanel { @@ -126,10 +123,9 @@ export class VariablesView extends ViewletPanel { } private onMouseDblClick(e: ITreeMouseEvent): void { - const element = e.element; const session = this.debugService.getViewModel().focusedSession; - if (element instanceof Variable && session.capabilities.supportsSetVariable) { - this.debugService.getViewModel().setSelectedExpression(element); + if (e.element instanceof Variable && session.capabilities.supportsSetVariable) { + this.debugService.getViewModel().setSelectedExpression(e.element); } } @@ -258,7 +254,6 @@ export class VariablesRenderer extends AbstractExpressionsRenderer { } class VariablesAccessibilityProvider implements IAccessibilityProvider { - getAriaLabel(element: IExpression | IScope): string { if (element instanceof Scope) { return nls.localize('variableScopeAriaLabel', "Scope {0}, variables, debug", element.name); diff --git a/src/vs/workbench/parts/debug/electron-browser/watchExpressionsView.ts b/src/vs/workbench/parts/debug/electron-browser/watchExpressionsView.ts index e5f1e5b6f23e076cfb9986edd2dda3f9368bb33f..b02c2204b80ee7f09854f534bebc6382d7855a65 100644 --- a/src/vs/workbench/parts/debug/electron-browser/watchExpressionsView.ts +++ b/src/vs/workbench/parts/debug/electron-browser/watchExpressionsView.ts @@ -195,7 +195,7 @@ class WatchExpressionsDataSource implements IDataSource { return true; } - return (element).hasChildren; + return element.hasChildren; } getChildren(element: IExpression | null): Thenable<(IExpression)[]> {