Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes Terminal: Focus Terminal Tabs view command not working #164408

Merged
merged 3 commits into from
Nov 3, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -179,14 +179,7 @@ export class TerminalGroupService extends Disposable implements ITerminalGroupSe
if (pane && !pane.isVisible()) {
await this._viewsService.openView(TERMINAL_VIEW_ID, focus);
}
// Do not await the focus as setVisible must be called immediately to ensure
// something else didn't steal focus
instance.focusWhenReady(true);
// HACK: as a workaround for https://github.com/microsoft/vscode/issues/134692,
// this will trigger a forced refresh of the viewport to sync the viewport and scroll bar.
// This can likely be removed after https://github.com/xtermjs/xterm.js/issues/291 is
// fixed upstream.
instance.setVisible(true);
await instance.focusWhenReady(true);
meganrogge marked this conversation as resolved.
Show resolved Hide resolved
}
}
this._onDidShow.fire();
Expand Down
6 changes: 0 additions & 6 deletions src/vs/workbench/contrib/terminal/browser/terminalView.ts
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@ import { ServicesAccessor } from 'vs/editor/browser/editorExtensions';
import { TerminalCapability } from 'vs/platform/terminal/common/capabilities/capabilities';

export class TerminalViewPane extends ViewPane {
private _actions: IAction[] | undefined;
meganrogge marked this conversation as resolved.
Show resolved Hide resolved
private _fontStyleElement: HTMLElement | undefined;
private _parentDomElement: HTMLElement | undefined;
private _terminalTabbedView?: TerminalTabbedView;
Expand Down Expand Up @@ -80,11 +79,6 @@ export class TerminalViewPane extends ViewPane {
) {
super(options, keybindingService, _contextMenuService, _configurationService, _contextKeyService, viewDescriptorService, _instantiationService, openerService, themeService, telemetryService);
this._register(this._terminalService.onDidRegisterProcessSupport(() => {
if (this._actions) {
for (const action of this._actions) {
action.enabled = true;
}
}
this._onDidChangeViewWelcomeState.fire();
}));

Expand Down