Fix terminal stealing focus from the multistep quick pick.
This is a little weird. onDidFocus is based on a focus tracker, but the focus() method is called when the terminal is actually expected to take focus. Fix #109538
This commit is contained in:
parent
949c3e089b
commit
a9bbd0c09c
|
@ -68,9 +68,6 @@ export class TerminalViewPane extends ViewPane {
|
|||
this._onDidChangeViewWelcomeState.fire();
|
||||
});
|
||||
|
||||
this._register(this.onDidFocus(() => {
|
||||
this._terminalService.getActiveTab()?.setWillFocus(true);
|
||||
}));
|
||||
this._register(this.onDidBlur(() => {
|
||||
this._terminalService.getActiveTab()?.setWillFocus(false);
|
||||
}));
|
||||
|
@ -219,6 +216,10 @@ export class TerminalViewPane extends ViewPane {
|
|||
return super.getActionViewItem(action);
|
||||
}
|
||||
|
||||
public focus() {
|
||||
this._terminalService.getActiveTab()?.setWillFocus(true);
|
||||
}
|
||||
|
||||
public focusFindWidget() {
|
||||
const activeInstance = this._terminalService.getActiveInstance();
|
||||
if (activeInstance && activeInstance.hasSelection() && activeInstance.selection!.indexOf('\n') === -1) {
|
||||
|
|
Loading…
Reference in a new issue