@@ -35,7 +35,7 @@ import { SideBySideEditor, EditorResourceAccessor } from '../../../common/editor
35
35
import { ICommandService , CommandsRegistry } from '../../../../platform/commands/common/commands.js' ;
36
36
import { IThemeService } from '../../../../platform/theme/common/themeService.js' ;
37
37
import { ThemeIcon } from '../../../../base/common/themables.js' ;
38
- import { IViewDescriptorService } from '../../../common/views.js' ;
38
+ import { IViewDescriptorService , ViewContainerLocation } from '../../../common/views.js' ;
39
39
import { IProgressService } from '../../../../platform/progress/common/progress.js' ;
40
40
import { IOpenerService } from '../../../../platform/opener/common/opener.js' ;
41
41
import { ActionBar , IActionViewItemProvider } from '../../../../base/browser/ui/actionbar/actionbar.js' ;
@@ -926,7 +926,7 @@ export class TimelinePane extends ViewPane {
926
926
// this.treeElement.classList.add('show-file-icons');
927
927
container . appendChild ( this . $tree ) ;
928
928
929
- this . treeRenderer = this . instantiationService . createInstance ( TimelineTreeRenderer , this . commands ) ;
929
+ this . treeRenderer = this . instantiationService . createInstance ( TimelineTreeRenderer , this . commands , this . viewDescriptorService . getViewLocationById ( this . id ) ) ;
930
930
this . _register ( this . treeRenderer . onDidScrollToEnd ( item => {
931
931
if ( this . pageOnScroll ) {
932
932
this . loadMore ( item ) ;
@@ -1165,11 +1165,18 @@ class TimelineTreeRenderer implements ITreeRenderer<TreeElement, FuzzyScore, Tim
1165
1165
1166
1166
constructor (
1167
1167
private readonly commands : TimelinePaneCommands ,
1168
+ private readonly viewContainerLocation : ViewContainerLocation | null ,
1168
1169
@IInstantiationService protected readonly instantiationService : IInstantiationService ,
1169
- @IThemeService private themeService : IThemeService ,
1170
+ @IThemeService private themeService : IThemeService
1170
1171
) {
1171
1172
this . actionViewItemProvider = createActionViewItem . bind ( undefined , this . instantiationService ) ;
1172
- this . _hoverDelegate = this . instantiationService . createInstance ( WorkbenchHoverDelegate , 'element' , { instantHover : true } , {
1173
+
1174
+ this . _hoverDelegate = this . instantiationService . createInstance (
1175
+ WorkbenchHoverDelegate ,
1176
+ this . viewContainerLocation === ViewContainerLocation . Panel ? 'mouse' : 'element' ,
1177
+ {
1178
+ instantHover : this . viewContainerLocation !== ViewContainerLocation . Panel
1179
+ } , {
1173
1180
position : {
1174
1181
hoverPosition : HoverPosition . RIGHT // Will flip when there's no space
1175
1182
}
0 commit comments