File tree 2 files changed +7
-4
lines changed
base/browser/ui/actionbar 2 files changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -22,6 +22,7 @@ export interface IActionViewItem extends IDisposable {
22
22
isEnabled ( ) : boolean ;
23
23
focus ( fromRight ?: boolean ) : void ; // TODO@isidorn what is this?
24
24
blur ( ) : void ;
25
+ showHover ?( ) : void ;
25
26
}
26
27
27
28
export interface IActionViewItemProvider {
@@ -282,6 +283,7 @@ export class ActionBar extends Disposable implements IActionRunner {
282
283
const elem = this . actionsList . children [ i ] ;
283
284
if ( DOM . isAncestor ( DOM . getActiveElement ( ) , elem ) ) {
284
285
this . focusedItem = i ;
286
+ this . viewItems [ this . focusedItem ] ?. showHover ?.( ) ;
285
287
break ;
286
288
}
287
289
}
@@ -544,8 +546,7 @@ export class ActionBar extends Disposable implements IActionRunner {
544
546
if ( this . previouslyFocusedItem !== undefined && this . previouslyFocusedItem !== this . focusedItem ) {
545
547
this . viewItems [ this . previouslyFocusedItem ] ?. blur ( ) ;
546
548
}
547
-
548
- const actionViewItem = this . focusedItem !== undefined && this . viewItems [ this . focusedItem ] ;
549
+ const actionViewItem = this . focusedItem !== undefined ? this . viewItems [ this . focusedItem ] : undefined ;
549
550
if ( actionViewItem ) {
550
551
let focusItem = true ;
551
552
@@ -560,7 +561,9 @@ export class ActionBar extends Disposable implements IActionRunner {
560
561
if ( actionViewItem . action . id === Separator . ID ) {
561
562
focusItem = false ;
562
563
}
563
-
564
+ if ( focusItem ) {
565
+ actionViewItem . showHover ?.( ) ;
566
+ }
564
567
if ( ! focusItem ) {
565
568
this . actionsList . focus ( { preventScroll } ) ;
566
569
this . previouslyFocusedItem = undefined ;
Original file line number Diff line number Diff line change @@ -415,7 +415,7 @@ export class CompoisteBarActionViewItem extends BaseActionViewItem {
415
415
} ) ) ;
416
416
}
417
417
418
- private showHover ( skipFadeInAnimation : boolean = false ) : void {
418
+ showHover ( skipFadeInAnimation : boolean = false ) : void {
419
419
if ( this . lastHover && ! this . lastHover . isDisposed ) {
420
420
return ;
421
421
}
You can’t perform that action at this time.
0 commit comments