@codingame/monaco-vscode-view-status-bar-service-override 13.1.7 → 14.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +5 -6
- package/vscode/src/vs/workbench/api/browser/statusBarExtensionPoint.js +12 -12
- package/vscode/src/vs/workbench/browser/parts/statusbar/statusbarActions.d.ts +7 -0
- package/vscode/src/vs/workbench/browser/parts/statusbar/statusbarActions.js +19 -4
- package/vscode/src/vs/workbench/browser/parts/statusbar/statusbarItem.js +20 -5
- package/vscode/src/vs/workbench/browser/parts/statusbar/statusbarModel.d.ts +1 -0
- package/vscode/src/vs/workbench/browser/parts/statusbar/statusbarPart.d.ts +5 -5
- package/vscode/src/vs/workbench/browser/parts/statusbar/statusbarPart.js +7 -3
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@codingame/monaco-vscode-view-status-bar-service-override",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "14.0.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "VSCode public API plugged on the monaco editor - view-status-bar service-override",
|
|
6
6
|
"keywords": [],
|
|
@@ -15,11 +15,10 @@
|
|
|
15
15
|
},
|
|
16
16
|
"type": "module",
|
|
17
17
|
"dependencies": {
|
|
18
|
-
"@codingame/monaco-vscode-0cc5da60-f921-59b9-bd8c-a018e93c0a6f-common": "
|
|
19
|
-
"@codingame/monaco-vscode-api": "
|
|
20
|
-
"@codingame/monaco-vscode-
|
|
21
|
-
"@codingame/monaco-vscode-d8236b3b-b91a-522d-89f4-94d70a546f6a-common": "
|
|
22
|
-
"@codingame/monaco-vscode-e7080bda-ce3e-5243-9a35-98cd9634dbda-common": "13.1.7"
|
|
18
|
+
"@codingame/monaco-vscode-0cc5da60-f921-59b9-bd8c-a018e93c0a6f-common": "14.0.0",
|
|
19
|
+
"@codingame/monaco-vscode-api": "14.0.0",
|
|
20
|
+
"@codingame/monaco-vscode-d4a98668-f793-5361-a9cf-1e6ae6d62ce3-common": "14.0.0",
|
|
21
|
+
"@codingame/monaco-vscode-d8236b3b-b91a-522d-89f4-94d70a546f6a-common": "14.0.0"
|
|
23
22
|
},
|
|
24
23
|
"main": "index.js",
|
|
25
24
|
"module": "index.js",
|
|
@@ -30,62 +30,62 @@ const statusBarItemSchema = {
|
|
|
30
30
|
id: {
|
|
31
31
|
type: 'string',
|
|
32
32
|
markdownDescription: ( localize(
|
|
33
|
-
|
|
33
|
+
2368,
|
|
34
34
|
'The identifier of the status bar entry. Must be unique within the extension. The same value must be used when calling the `vscode.window.createStatusBarItem(id, ...)`-API'
|
|
35
35
|
))
|
|
36
36
|
},
|
|
37
37
|
name: {
|
|
38
38
|
type: 'string',
|
|
39
39
|
description: ( localize(
|
|
40
|
-
|
|
40
|
+
2369,
|
|
41
41
|
'The name of the entry, like \'Python Language Indicator\', \'Git Status\' etc. Try to keep the length of the name short, yet descriptive enough that users can understand what the status bar item is about.'
|
|
42
42
|
))
|
|
43
43
|
},
|
|
44
44
|
text: {
|
|
45
45
|
type: 'string',
|
|
46
46
|
description: ( localize(
|
|
47
|
-
|
|
47
|
+
2370,
|
|
48
48
|
'The text to show for the entry. You can embed icons in the text by leveraging the `$(<name>)`-syntax, like \'Hello $(globe)!\''
|
|
49
49
|
))
|
|
50
50
|
},
|
|
51
51
|
tooltip: {
|
|
52
52
|
type: 'string',
|
|
53
|
-
description: ( localize(
|
|
53
|
+
description: ( localize(2371, 'The tooltip text for the entry.'))
|
|
54
54
|
},
|
|
55
55
|
command: {
|
|
56
56
|
type: 'string',
|
|
57
|
-
description: ( localize(
|
|
57
|
+
description: ( localize(2372, 'The command to execute when the status bar entry is clicked.'))
|
|
58
58
|
},
|
|
59
59
|
alignment: {
|
|
60
60
|
type: 'string',
|
|
61
61
|
enum: ['left', 'right'],
|
|
62
|
-
description: ( localize(
|
|
62
|
+
description: ( localize(2373, 'The alignment of the status bar entry.'))
|
|
63
63
|
},
|
|
64
64
|
priority: {
|
|
65
65
|
type: 'number',
|
|
66
66
|
description: ( localize(
|
|
67
|
-
|
|
67
|
+
2374,
|
|
68
68
|
'The priority of the status bar entry. Higher value means the item should be shown more to the left.'
|
|
69
69
|
))
|
|
70
70
|
},
|
|
71
71
|
accessibilityInformation: {
|
|
72
72
|
type: 'object',
|
|
73
73
|
description: ( localize(
|
|
74
|
-
|
|
74
|
+
2375,
|
|
75
75
|
'Defines the role and aria label to be used when the status bar entry is focused.'
|
|
76
76
|
)),
|
|
77
77
|
properties: {
|
|
78
78
|
role: {
|
|
79
79
|
type: 'string',
|
|
80
80
|
description: ( localize(
|
|
81
|
-
|
|
81
|
+
2376,
|
|
82
82
|
'The role of the status bar entry which defines how a screen reader interacts with it. More about aria roles can be found here https://w3c.github.io/aria/#widget_roles'
|
|
83
83
|
))
|
|
84
84
|
},
|
|
85
85
|
label: {
|
|
86
86
|
type: 'string',
|
|
87
87
|
description: ( localize(
|
|
88
|
-
|
|
88
|
+
2377,
|
|
89
89
|
'The aria label of the status bar entry. Defaults to the entry\'s text.'
|
|
90
90
|
))
|
|
91
91
|
}
|
|
@@ -94,7 +94,7 @@ const statusBarItemSchema = {
|
|
|
94
94
|
}
|
|
95
95
|
};
|
|
96
96
|
const statusBarItemsSchema = {
|
|
97
|
-
description: ( localize(
|
|
97
|
+
description: ( localize(2378, "Contributes items to the status bar.")),
|
|
98
98
|
oneOf: [
|
|
99
99
|
statusBarItemSchema,
|
|
100
100
|
{
|
|
@@ -120,7 +120,7 @@ let StatusBarItemsExtensionPoint = class StatusBarItemsExtensionPoint {
|
|
|
120
120
|
const { value, collector } = entry;
|
|
121
121
|
for (const candidate of Iterable.wrap(value)) {
|
|
122
122
|
if (!isUserFriendlyStatusItemEntry(candidate)) {
|
|
123
|
-
collector.error(( localize(
|
|
123
|
+
collector.error(( localize(2379, "Invalid status bar item contribution.")));
|
|
124
124
|
continue;
|
|
125
125
|
}
|
|
126
126
|
const fullItemId = asStatusBarItemIdentifier(entry.description.identifier, candidate.id);
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { Action } from "@codingame/monaco-vscode-api/vscode/vs/base/common/actions";
|
|
2
2
|
import { StatusbarViewModel } from "./statusbarModel.js";
|
|
3
|
+
import { ICommandService } from "@codingame/monaco-vscode-api/vscode/vs/platform/commands/common/commands.service";
|
|
3
4
|
export declare class ToggleStatusbarEntryVisibilityAction extends Action {
|
|
4
5
|
private model;
|
|
5
6
|
constructor(id: string, label: string, model: StatusbarViewModel);
|
|
@@ -10,3 +11,9 @@ export declare class HideStatusbarEntryAction extends Action {
|
|
|
10
11
|
constructor(id: string, name: string, model: StatusbarViewModel);
|
|
11
12
|
run(): Promise<void>;
|
|
12
13
|
}
|
|
14
|
+
export declare class ManageExtensionAction extends Action {
|
|
15
|
+
private readonly extensionId;
|
|
16
|
+
private readonly commandService;
|
|
17
|
+
constructor(extensionId: string, commandService: ICommandService);
|
|
18
|
+
run(): Promise<void>;
|
|
19
|
+
}
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
|
|
2
|
+
import { __decorate, __param } from '@codingame/monaco-vscode-api/external/tslib/tslib.es6';
|
|
2
3
|
import { localize, localize2 } from '@codingame/monaco-vscode-api/vscode/vs/nls';
|
|
3
4
|
import { IStatusbarService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/statusbar/browser/statusbar.service';
|
|
4
5
|
import { Action } from '@codingame/monaco-vscode-api/vscode/vs/base/common/actions';
|
|
5
|
-
import { Parts } from '@codingame/monaco-vscode-
|
|
6
|
+
import { Parts } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/layout/browser/layoutService';
|
|
6
7
|
import { IWorkbenchLayoutService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/layout/browser/layoutService.service';
|
|
7
8
|
import { KeyCode } from '@codingame/monaco-vscode-api/vscode/vs/base/common/keyCodes';
|
|
8
9
|
import { KeybindingsRegistry, KeybindingWeight } from '@codingame/monaco-vscode-api/vscode/vs/platform/keybinding/common/keybindingsRegistry';
|
|
@@ -11,6 +12,7 @@ import { Categories } from '@codingame/monaco-vscode-api/vscode/vs/platform/acti
|
|
|
11
12
|
import { IEditorService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/editor/common/editorService.service';
|
|
12
13
|
import { StatusBarFocused } from '@codingame/monaco-vscode-api/vscode/vs/workbench/common/contextkeys';
|
|
13
14
|
import { getActiveWindow } from '@codingame/monaco-vscode-api/vscode/vs/base/browser/dom';
|
|
15
|
+
import { ICommandService } from '@codingame/monaco-vscode-api/vscode/vs/platform/commands/common/commands.service';
|
|
14
16
|
|
|
15
17
|
class ToggleStatusbarEntryVisibilityAction extends Action {
|
|
16
18
|
constructor(id, label, model) {
|
|
@@ -29,13 +31,26 @@ class ToggleStatusbarEntryVisibilityAction extends Action {
|
|
|
29
31
|
}
|
|
30
32
|
class HideStatusbarEntryAction extends Action {
|
|
31
33
|
constructor(id, name, model) {
|
|
32
|
-
super(id, ( localize(
|
|
34
|
+
super(id, ( localize(3374, "Hide '{0}'", name)), undefined, true);
|
|
33
35
|
this.model = model;
|
|
34
36
|
}
|
|
35
37
|
async run() {
|
|
36
38
|
this.model.hide(this.id);
|
|
37
39
|
}
|
|
38
40
|
}
|
|
41
|
+
let ManageExtensionAction = class ManageExtensionAction extends Action {
|
|
42
|
+
constructor(extensionId, commandService) {
|
|
43
|
+
super('statusbar.manage.extension', ( localize(3375, "Manage Extension")));
|
|
44
|
+
this.extensionId = extensionId;
|
|
45
|
+
this.commandService = commandService;
|
|
46
|
+
}
|
|
47
|
+
run() {
|
|
48
|
+
return this.commandService.executeCommand('_extensions.manage', this.extensionId);
|
|
49
|
+
}
|
|
50
|
+
};
|
|
51
|
+
ManageExtensionAction = ( __decorate([
|
|
52
|
+
( __param(1, ICommandService))
|
|
53
|
+
], ManageExtensionAction));
|
|
39
54
|
KeybindingsRegistry.registerCommandAndKeybindingRule({
|
|
40
55
|
id: 'workbench.statusBar.focusPrevious',
|
|
41
56
|
weight: KeybindingWeight.WorkbenchContrib,
|
|
@@ -100,7 +115,7 @@ class FocusStatusBarAction extends Action2 {
|
|
|
100
115
|
constructor() {
|
|
101
116
|
super({
|
|
102
117
|
id: 'workbench.action.focusStatusBar',
|
|
103
|
-
title: ( localize2(
|
|
118
|
+
title: ( localize2(3376, 'Focus Status Bar')),
|
|
104
119
|
category: Categories.View,
|
|
105
120
|
f1: true
|
|
106
121
|
});
|
|
@@ -112,4 +127,4 @@ class FocusStatusBarAction extends Action2 {
|
|
|
112
127
|
}
|
|
113
128
|
registerAction2(FocusStatusBarAction);
|
|
114
129
|
|
|
115
|
-
export { HideStatusbarEntryAction, ToggleStatusbarEntryVisibilityAction };
|
|
130
|
+
export { HideStatusbarEntryAction, ManageExtensionAction, ToggleStatusbarEntryVisibilityAction };
|
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
import { __decorate, __param } from '@codingame/monaco-vscode-api/external/tslib/tslib.es6';
|
|
3
3
|
import { toErrorMessage } from '@codingame/monaco-vscode-api/vscode/vs/base/common/errorMessage';
|
|
4
4
|
import { Disposable, MutableDisposable } from '@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle';
|
|
5
|
-
import { SimpleIconLabel } from '@codingame/monaco-vscode-
|
|
5
|
+
import { SimpleIconLabel } from '@codingame/monaco-vscode-d4a98668-f793-5361-a9cf-1e6ae6d62ce3-common/vscode/vs/base/browser/ui/iconLabel/simpleIconLabel';
|
|
6
6
|
import { ICommandService } from '@codingame/monaco-vscode-api/vscode/vs/platform/commands/common/commands.service';
|
|
7
7
|
import { ITelemetryService } from '@codingame/monaco-vscode-api/vscode/vs/platform/telemetry/common/telemetry.service';
|
|
8
|
-
import { ShowTooltipCommand, StatusbarEntryKinds } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/statusbar/browser/statusbar';
|
|
8
|
+
import { isTooltipWithCommands, ShowTooltipCommand, StatusbarEntryKinds } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/statusbar/browser/statusbar';
|
|
9
9
|
import { IThemeService } from '@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/themeService.service';
|
|
10
10
|
import { isThemeColor } from '@codingame/monaco-vscode-api/vscode/vs/editor/common/editorCommon';
|
|
11
11
|
import { show, hide, addDisposableListener, EventType, EventHelper, append } from '@codingame/monaco-vscode-api/vscode/vs/base/browser/dom';
|
|
@@ -73,12 +73,27 @@ let StatusbarEntryItem = class StatusbarEntryItem extends Disposable {
|
|
|
73
73
|
this.labelContainer.setAttribute('role', entry.role || 'button');
|
|
74
74
|
}
|
|
75
75
|
if (!this.entry || !this.isEqualTooltip(this.entry, entry)) {
|
|
76
|
-
|
|
76
|
+
let hoverOptions;
|
|
77
|
+
let hoverTooltip;
|
|
78
|
+
if (isTooltipWithCommands(entry.tooltip)) {
|
|
79
|
+
hoverTooltip = entry.tooltip.content;
|
|
80
|
+
hoverOptions = {
|
|
81
|
+
actions: ( entry.tooltip.commands.map(command => ({
|
|
82
|
+
commandId: command.id,
|
|
83
|
+
label: command.title,
|
|
84
|
+
run: () => this.executeCommand(command)
|
|
85
|
+
})))
|
|
86
|
+
};
|
|
87
|
+
}
|
|
88
|
+
else {
|
|
89
|
+
hoverTooltip = entry.tooltip;
|
|
90
|
+
}
|
|
91
|
+
const hoverContents = isMarkdownString(hoverTooltip) ? { markdown: hoverTooltip, markdownNotSupportedFallback: undefined } : hoverTooltip;
|
|
77
92
|
if (this.hover) {
|
|
78
|
-
this.hover.update(hoverContents);
|
|
93
|
+
this.hover.update(hoverContents, hoverOptions);
|
|
79
94
|
}
|
|
80
95
|
else {
|
|
81
|
-
this.hover = this._register(this.hoverService.setupManagedHover(this.hoverDelegate, this.container, hoverContents));
|
|
96
|
+
this.hover = this._register(this.hoverService.setupManagedHover(this.hoverDelegate, this.container, hoverContents, hoverOptions));
|
|
82
97
|
}
|
|
83
98
|
}
|
|
84
99
|
if (!this.entry || entry.command !== this.entry.command) {
|
|
@@ -3,6 +3,7 @@ import { IStatusbarEntryPriority, StatusbarAlignment } from "@codingame/monaco-v
|
|
|
3
3
|
import { IStorageService } from "@codingame/monaco-vscode-api/vscode/vs/platform/storage/common/storage.service";
|
|
4
4
|
export interface IStatusbarViewModelEntry {
|
|
5
5
|
readonly id: string;
|
|
6
|
+
readonly extensionId: string | undefined;
|
|
6
7
|
readonly name: string;
|
|
7
8
|
readonly hasCommand: boolean;
|
|
8
9
|
readonly alignment: StatusbarAlignment;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Disposable, DisposableStore, IDisposable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle";
|
|
2
2
|
import { MultiWindowParts, Part } from "@codingame/monaco-vscode-d8236b3b-b91a-522d-89f4-94d70a546f6a-common/vscode/vs/workbench/browser/part";
|
|
3
3
|
import { IInstantiationService } from "@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/instantiation";
|
|
4
|
-
import { StatusbarAlignment, IStatusbarEntry, IStatusbarEntryAccessor, IStatusbarStyleOverride, IStatusbarEntryLocation, IStatusbarEntryPriority
|
|
4
|
+
import { StatusbarAlignment, IStatusbarEntry, IStatusbarEntryAccessor, IStatusbarStyleOverride, IStatusbarEntryLocation, IStatusbarEntryPriority } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/statusbar/browser/statusbar";
|
|
5
5
|
import { IStatusbarService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/statusbar/browser/statusbar.service";
|
|
6
6
|
import { IContextMenuService } from "@codingame/monaco-vscode-api/vscode/vs/platform/contextview/browser/contextView.service";
|
|
7
7
|
import { IThemeService } from "@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/themeService.service";
|
|
@@ -21,7 +21,7 @@ export interface IStatusbarEntryContainer extends IDisposable {
|
|
|
21
21
|
addEntry(entry: IStatusbarEntry, id: string, alignment: StatusbarAlignment, location?: IStatusbarEntryLocation): IStatusbarEntryAccessor;
|
|
22
22
|
isEntryVisible(id: string): boolean;
|
|
23
23
|
updateEntryVisibility(id: string, visible: boolean): void;
|
|
24
|
-
overrideEntry(id: string, override:
|
|
24
|
+
overrideEntry(id: string, override: Partial<IStatusbarEntry>): IDisposable;
|
|
25
25
|
focus(preserveEntryFocus?: boolean): void;
|
|
26
26
|
focusNextEntry(): void;
|
|
27
27
|
focusPreviousEntry(): void;
|
|
@@ -57,7 +57,7 @@ declare class StatusbarPart extends Part implements IStatusbarEntryContainer {
|
|
|
57
57
|
private readonly styleOverrides;
|
|
58
58
|
constructor(id: string, instantiationService: IInstantiationService, themeService: IThemeService, contextService: IWorkspaceContextService, storageService: IStorageService, layoutService: IWorkbenchLayoutService, contextMenuService: IContextMenuService, contextKeyService: IContextKeyService);
|
|
59
59
|
private registerListeners;
|
|
60
|
-
overrideEntry(id: string, override:
|
|
60
|
+
overrideEntry(id: string, override: Partial<IStatusbarEntry>): IDisposable;
|
|
61
61
|
private withEntryOverride;
|
|
62
62
|
addEntry(entry: IStatusbarEntry, id: string, alignment: StatusbarAlignment, priorityOrLocation?: number | IStatusbarEntryLocation | IStatusbarEntryPriority): IStatusbarEntryAccessor;
|
|
63
63
|
private doAddPendingEntry;
|
|
@@ -113,7 +113,7 @@ export declare class StatusbarService extends MultiWindowParts<StatusbarPart> im
|
|
|
113
113
|
private doAddEntryToAllWindows;
|
|
114
114
|
isEntryVisible(id: string): boolean;
|
|
115
115
|
updateEntryVisibility(id: string, visible: boolean): void;
|
|
116
|
-
overrideEntry(id: string, override:
|
|
116
|
+
overrideEntry(id: string, override: Partial<IStatusbarEntry>): IDisposable;
|
|
117
117
|
focus(preserveEntryFocus?: boolean): void;
|
|
118
118
|
focusNextEntry(): void;
|
|
119
119
|
focusPreviousEntry(): void;
|
|
@@ -135,7 +135,7 @@ export declare class ScopedStatusbarService extends Disposable implements IStatu
|
|
|
135
135
|
addEntry(entry: IStatusbarEntry, id: string, alignment: StatusbarAlignment, priorityOrLocation?: number | IStatusbarEntryLocation | IStatusbarEntryPriority): IStatusbarEntryAccessor;
|
|
136
136
|
isEntryVisible(id: string): boolean;
|
|
137
137
|
updateEntryVisibility(id: string, visible: boolean): void;
|
|
138
|
-
overrideEntry(id: string, override:
|
|
138
|
+
overrideEntry(id: string, override: Partial<IStatusbarEntry>): IDisposable;
|
|
139
139
|
focus(preserveEntryFocus?: boolean): void;
|
|
140
140
|
focusNextEntry(): void;
|
|
141
141
|
focusPreviousEntry(): void;
|
|
@@ -28,7 +28,7 @@ import '@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/colors/sear
|
|
|
28
28
|
import { addDisposableListener, EventType, clearNode, EventHelper, getWindow } from '@codingame/monaco-vscode-api/vscode/vs/base/browser/dom';
|
|
29
29
|
import { createStyleSheet } from '@codingame/monaco-vscode-api/vscode/vs/base/browser/domStylesheets';
|
|
30
30
|
import { IStorageService } from '@codingame/monaco-vscode-api/vscode/vs/platform/storage/common/storage.service';
|
|
31
|
-
import { Parts } from '@codingame/monaco-vscode-
|
|
31
|
+
import { Parts } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/layout/browser/layoutService';
|
|
32
32
|
import { IWorkbenchLayoutService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/layout/browser/layoutService.service';
|
|
33
33
|
import '@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/extensions';
|
|
34
34
|
import { equals } from '@codingame/monaco-vscode-api/vscode/vs/base/common/arrays';
|
|
@@ -39,7 +39,7 @@ import { IContextKeyService } from '@codingame/monaco-vscode-api/vscode/vs/platf
|
|
|
39
39
|
import { isHighContrast } from '@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/theme';
|
|
40
40
|
import { hash } from '@codingame/monaco-vscode-api/vscode/vs/base/common/hash';
|
|
41
41
|
import { WorkbenchHoverDelegate } from '@codingame/monaco-vscode-api/vscode/vs/platform/hover/browser/hover';
|
|
42
|
-
import { ToggleStatusbarEntryVisibilityAction, HideStatusbarEntryAction } from './statusbarActions.js';
|
|
42
|
+
import { ToggleStatusbarEntryVisibilityAction, ManageExtensionAction, HideStatusbarEntryAction } from './statusbarActions.js';
|
|
43
43
|
import { StatusbarViewModel } from './statusbarModel.js';
|
|
44
44
|
import { StatusbarEntryItem } from './statusbarItem.js';
|
|
45
45
|
import { StatusBarFocused } from '@codingame/monaco-vscode-api/vscode/vs/workbench/common/contextkeys';
|
|
@@ -145,6 +145,7 @@ let StatusbarPart = class StatusbarPart extends Part {
|
|
|
145
145
|
const viewModelEntry = new class {
|
|
146
146
|
constructor() {
|
|
147
147
|
this.id = id;
|
|
148
|
+
this.extensionId = entry.extensionId;
|
|
148
149
|
this.alignment = alignment;
|
|
149
150
|
this.priority = priority;
|
|
150
151
|
this.container = itemContainer;
|
|
@@ -383,7 +384,7 @@ let StatusbarPart = class StatusbarPart extends Part {
|
|
|
383
384
|
}
|
|
384
385
|
getContextMenuActions(event) {
|
|
385
386
|
const actions = [];
|
|
386
|
-
actions.push(toAction({ id: ToggleStatusbarVisibilityAction.ID, label: ( localize(
|
|
387
|
+
actions.push(toAction({ id: ToggleStatusbarVisibilityAction.ID, label: ( localize(3377, "Hide Status Bar")), run: () => this.instantiationService.invokeFunction(accessor => ( new ToggleStatusbarVisibilityAction()).run(accessor)) }));
|
|
387
388
|
actions.push(( new Separator()));
|
|
388
389
|
const handledEntries = ( new Set());
|
|
389
390
|
for (const entry of this.viewModel.entries) {
|
|
@@ -402,6 +403,9 @@ let StatusbarPart = class StatusbarPart extends Part {
|
|
|
402
403
|
}
|
|
403
404
|
if (statusEntryUnderMouse) {
|
|
404
405
|
actions.push(( new Separator()));
|
|
406
|
+
if (statusEntryUnderMouse.extensionId) {
|
|
407
|
+
actions.push(this.instantiationService.createInstance(ManageExtensionAction, statusEntryUnderMouse.extensionId));
|
|
408
|
+
}
|
|
405
409
|
actions.push(( new HideStatusbarEntryAction(statusEntryUnderMouse.id, statusEntryUnderMouse.name, this.viewModel)));
|
|
406
410
|
}
|
|
407
411
|
return actions;
|