Skip to content

Commit 245b24a

Browse files
authored
do not deal with single tab in disposable (#239865)
1 parent c659faf commit 245b24a

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

src/vs/workbench/contrib/terminal/browser/terminalView.ts

+1-6
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,6 @@ import { MicrotaskDelay } from '../../../../base/common/symbols.js';
5555
export class TerminalViewPane extends ViewPane {
5656
private _parentDomElement: HTMLElement | undefined;
5757
private _terminalTabbedView?: TerminalTabbedView;
58-
private readonly _singleTabActionViewItem: MutableDisposable<SingleTerminalTabActionViewItem> = this._register(new MutableDisposable());
5958
get terminalTabbedView(): TerminalTabbedView | undefined { return this._terminalTabbedView; }
6059
private _isInitialized: boolean = false;
6160
/**
@@ -280,12 +279,8 @@ export class TerminalViewPane extends ViewPane {
280279
}
281280
case TerminalCommandId.Focus: {
282281
if (action instanceof MenuItemAction) {
283-
if (this._singleTabActionViewItem.value) {
284-
return this._singleTabActionViewItem.value;
285-
}
286282
const actions = getFlatContextMenuActions(this._singleTabMenu.getActions({ shouldForwardArgs: true }));
287-
this._singleTabActionViewItem.value = this._instantiationService.createInstance(SingleTerminalTabActionViewItem, action, actions);
288-
return this._singleTabActionViewItem.value;
283+
return this._instantiationService.createInstance(SingleTerminalTabActionViewItem, action, actions);
289284
}
290285
break;
291286
}

0 commit comments

Comments
 (0)