diff --git a/src/vs/workbench/parts/debug/common/debugModel.ts b/src/vs/workbench/parts/debug/common/debugModel.ts index 95991921377c63a257d9ba793b61207973b174d0..607900c2bff22d83c1b86cf7cbc643f19b8e5fdc 100644 --- a/src/vs/workbench/parts/debug/common/debugModel.ts +++ b/src/vs/workbench/parts/debug/common/debugModel.ts @@ -288,24 +288,10 @@ export class Variable extends ExpressionContainer implements debug.IExpression { } } -export class Scope implements debug.IScope { +export class Scope extends ExpressionContainer implements debug.IScope { - private children: TPromise; - - constructor(private threadId: number, public name: string, public reference: number, public expensive: boolean) { - this.children = null; - } - - public getId(): string { - return `scope:${ this.threadId }:${ this.name }:${ this.reference }`; - } - - public getChildren(debugService: debug.IDebugService): TPromise { - if (!this.children) { - this.children = resolveChildren(debugService, this); - } - - return this.children; + constructor(private threadId: number, public name: string, reference: number, public expensive: boolean) { + super(reference, `scope:${threadId}:${name}:${reference}`, true); } }