File tree Expand file tree Collapse file tree 1 file changed +8
-0
lines changed
src/vs/workbench/contrib/scm/browser Expand file tree Collapse file tree 1 file changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -230,6 +230,7 @@ export class SCMRepositoriesViewPane extends ViewPane {
230230
231231 this . _register ( this . tree . onDidChangeSelection ( this . onTreeSelectionChange , this ) ) ;
232232 this . _register ( this . tree . onDidChangeFocus ( this . onTreeDidChangeFocus , this ) ) ;
233+ this . _register ( this . tree . onDidFocus ( this . onDidTreeFocus , this ) ) ;
233234 this . _register ( this . tree . onContextMenu ( this . onTreeContextMenu , this ) ) ;
234235 this . _register ( this . tree . onDidChangeContentHeight ( this . onTreeContentHeightChange , this ) ) ;
235236 }
@@ -274,6 +275,13 @@ export class SCMRepositoriesViewPane extends ViewPane {
274275 }
275276 }
276277
278+ private onDidTreeFocus ( ) : void {
279+ const focused = this . tree . getFocus ( ) ;
280+ if ( focused . length > 0 ) {
281+ this . scmViewService . focus ( focused [ 0 ] ) ;
282+ }
283+ }
284+
277285 private onTreeContentHeightChange ( height : number ) : void {
278286 this . updateBodySize ( height ) ;
279287
You can’t perform that action at this time.
0 commit comments