File tree Expand file tree Collapse file tree 2 files changed +8
-5
lines changed
terminalContrib/accessibility/browser Expand file tree Collapse file tree 2 files changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -976,6 +976,13 @@ export class TerminalInstance extends Disposable implements ITerminalInstance {
976
976
return false ;
977
977
}
978
978
979
+ // Prevent default when shift+tab is being sent to the terminal to avoid it bubbling up
980
+ // and changing focus https://github.com/microsoft/vscode/issues/188329
981
+ if ( event . key === 'Tab' && event . shiftKey ) {
982
+ event . preventDefault ( ) ;
983
+ return true ;
984
+ }
985
+
979
986
// Always have alt+F4 skip the terminal on Windows and allow it to be handled by the
980
987
// system
981
988
if ( isWindows && event . altKey && event . key === 'F4' && ! event . ctrlKey ) {
Original file line number Diff line number Diff line change @@ -118,17 +118,13 @@ export abstract class TerminalAccessibleWidget extends DisposableStore {
118
118
// On escape, hide the accessible buffer and force focus onto the terminal
119
119
this . hide ( true ) ;
120
120
break ;
121
- case KeyCode . Tab :
122
- // On tab or shift+tab, hide the accessible buffer and perform the default tab
123
- // behavior
124
- this . hide ( ) ;
125
- break ;
126
121
}
127
122
} ) ) ;
128
123
this . add ( this . _editorWidget . onDidFocusEditorText ( async ( ) => {
129
124
this . _terminalService . setActiveInstance ( this . _instance as ITerminalInstance ) ;
130
125
this . _xtermElement . classList . add ( ClassName . Hide ) ;
131
126
} ) ) ;
127
+ this . add ( this . _editorWidget . onDidBlurEditorText ( async ( ) => this . hide ( ) ) ) ;
132
128
}
133
129
134
130
registerListeners ( ) : void {
You can’t perform that action at this time.
0 commit comments