refactor: add siHome into context.subscriptions

This commit is contained in:
Levi Yan
2024-07-03 11:55:49 +08:00
parent f044c4770a
commit fed0b5ddad
2 changed files with 7 additions and 2 deletions

View File

@@ -1,8 +1,10 @@
import * as vscode from 'vscode';
export default class SIHome {
context: vscode.ExtensionContext;
constructor() {
constructor(context: vscode.ExtensionContext) {
this.context = context;
}
toggle(url: string) {
@@ -32,7 +34,10 @@ export default class SIHome {
}
},
undefined,
this.context.subscriptions
);
this.context.subscriptions.push(panel)
}

View File

@@ -11,7 +11,7 @@ export class SuperIDEExtension {
siHome: SIHome;
constructor(private context: vscode.ExtensionContext) {
this.siHome = new SIHome();
this.siHome = new SIHome(context);
context.subscriptions.push(
vscode.window.registerTreeDataProvider(