Skip to content

Commit 2bc9214

Browse files
[AXON-1314] fix: updade help section w/ rovodev consistently (#1106)
1 parent 418c47d commit 2bc9214

File tree

2 files changed

+13
-1
lines changed

2 files changed

+13
-1
lines changed

src/container.ts

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,7 @@ export class Container {
8080
private static _commonMessageHandler: CommonActionMessageHandler;
8181
private static _bitbucketHelper: CheckoutHelper;
8282
private static _assignedWorkItemsView: AssignedWorkItemsViewProvider;
83+
private static _helpExplorer: HelpExplorer;
8384

8485
static async initialize(context: ExtensionContext, version: string) {
8586
canFetchInternalUrl().then((success) => {
@@ -194,7 +195,8 @@ export class Container {
194195

195196
this._loginManager = new LoginManager(this._credentialManager, this._siteManager, this._analyticsClient);
196197
this._bitbucketHelper = new BitbucketCheckoutHelper(context.globalState);
197-
context.subscriptions.push(new HelpExplorer());
198+
this._helpExplorer = new HelpExplorer();
199+
context.subscriptions.push(this._helpExplorer);
198200

199201
this._featureFlagClient = FeatureFlagClient.getInstance();
200202

@@ -324,6 +326,9 @@ export class Container {
324326
);
325327

326328
context.subscriptions.push(this._rovodevDisposable);
329+
330+
// Update help explorer to show Rovo Dev content
331+
this._helpExplorer.refresh();
327332
} catch (error) {
328333
RovoDevLogger.error(error, 'Enabling Rovo Dev');
329334
}
@@ -344,6 +349,9 @@ export class Container {
344349
return;
345350
}
346351

352+
// Update help explorer to hide Rovo Dev content
353+
this._helpExplorer.refresh();
354+
347355
try {
348356
await setCommandContext(CommandContext.RovoDevEnabled, false);
349357
this._rovodevDisposable.dispose();

src/views/HelpExplorer.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,4 +28,8 @@ export class HelpExplorer extends Explorer implements Disposable {
2828
async handleFocusEvent(e: FocusEvent) {
2929
//No focus available for now
3030
}
31+
32+
refresh() {
33+
this.newTreeView();
34+
}
3135
}

0 commit comments

Comments
 (0)