@theia/navigator 1.67.0-next.56 → 1.67.0-next.59
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/lib/browser/abstract-navigator-tree-widget.d.ts +11 -0
- package/lib/browser/abstract-navigator-tree-widget.d.ts.map +1 -0
- package/lib/browser/abstract-navigator-tree-widget.js +62 -0
- package/lib/browser/abstract-navigator-tree-widget.js.map +1 -0
- package/lib/browser/file-navigator-commands.d.ts +19 -0
- package/lib/browser/file-navigator-commands.d.ts.map +1 -0
- package/lib/browser/file-navigator-commands.js +76 -0
- package/lib/browser/file-navigator-commands.js.map +1 -0
- package/lib/browser/index.d.ts +5 -0
- package/lib/browser/index.d.ts.map +1 -0
- package/lib/browser/index.js +23 -0
- package/lib/browser/index.js.map +1 -0
- package/lib/browser/navigator-container.d.ts +7 -0
- package/lib/browser/navigator-container.d.ts.map +1 -0
- package/lib/browser/navigator-container.js +48 -0
- package/lib/browser/navigator-container.js.map +1 -0
- package/lib/browser/navigator-context-key-service.d.ts +21 -0
- package/lib/browser/navigator-context-key-service.d.ts.map +1 -0
- package/lib/browser/navigator-context-key-service.js +65 -0
- package/lib/browser/navigator-context-key-service.js.map +1 -0
- package/lib/browser/navigator-contribution.d.ts +111 -0
- package/lib/browser/navigator-contribution.d.ts.map +1 -0
- package/lib/browser/navigator-contribution.js +616 -0
- package/lib/browser/navigator-contribution.js.map +1 -0
- package/lib/browser/navigator-decorator-service.d.ts +14 -0
- package/lib/browser/navigator-decorator-service.d.ts.map +1 -0
- package/lib/browser/navigator-decorator-service.js +43 -0
- package/lib/browser/navigator-decorator-service.js.map +1 -0
- package/lib/browser/navigator-diff.d.ts +39 -0
- package/lib/browser/navigator-diff.d.ts.map +1 -0
- package/lib/browser/navigator-diff.js +131 -0
- package/lib/browser/navigator-diff.js.map +1 -0
- package/lib/browser/navigator-diff.spec.d.ts +2 -0
- package/lib/browser/navigator-diff.spec.d.ts.map +1 -0
- package/lib/browser/navigator-diff.spec.js +100 -0
- package/lib/browser/navigator-diff.spec.js.map +1 -0
- package/lib/browser/navigator-filter.d.ts +72 -0
- package/lib/browser/navigator-filter.d.ts.map +1 -0
- package/lib/browser/navigator-filter.js +130 -0
- package/lib/browser/navigator-filter.js.map +1 -0
- package/lib/browser/navigator-filter.spec.d.ts +2 -0
- package/lib/browser/navigator-filter.spec.d.ts.map +1 -0
- package/lib/browser/navigator-filter.spec.js +131 -0
- package/lib/browser/navigator-filter.spec.js.map +1 -0
- package/lib/browser/navigator-frontend-module.d.ts +6 -0
- package/lib/browser/navigator-frontend-module.d.ts.map +1 -0
- package/lib/browser/navigator-frontend-module.js +76 -0
- package/lib/browser/navigator-frontend-module.js.map +1 -0
- package/lib/browser/navigator-layout-migrations.d.ts +10 -0
- package/lib/browser/navigator-layout-migrations.d.ts.map +1 -0
- package/lib/browser/navigator-layout-migrations.js +76 -0
- package/lib/browser/navigator-layout-migrations.js.map +1 -0
- package/lib/browser/navigator-model.d.ts +44 -0
- package/lib/browser/navigator-model.d.ts.map +1 -0
- package/lib/browser/navigator-model.js +229 -0
- package/lib/browser/navigator-model.js.map +1 -0
- package/lib/browser/navigator-symlink-decorator.d.ts +14 -0
- package/lib/browser/navigator-symlink-decorator.d.ts.map +1 -0
- package/lib/browser/navigator-symlink-decorator.js +74 -0
- package/lib/browser/navigator-symlink-decorator.js.map +1 -0
- package/lib/browser/navigator-tab-bar-decorator.d.ts +17 -0
- package/lib/browser/navigator-tab-bar-decorator.d.ts.map +1 -0
- package/lib/browser/navigator-tab-bar-decorator.js +71 -0
- package/lib/browser/navigator-tab-bar-decorator.js.map +1 -0
- package/lib/browser/navigator-tree.d.ts +43 -0
- package/lib/browser/navigator-tree.d.ts.map +1 -0
- package/lib/browser/navigator-tree.js +125 -0
- package/lib/browser/navigator-tree.js.map +1 -0
- package/lib/browser/navigator-widget-factory.d.ts +13 -0
- package/lib/browser/navigator-widget-factory.d.ts.map +1 -0
- package/lib/browser/navigator-widget-factory.js +76 -0
- package/lib/browser/navigator-widget-factory.js.map +1 -0
- package/lib/browser/navigator-widget.d.ts +46 -0
- package/lib/browser/navigator-widget.d.ts.map +1 -0
- package/lib/browser/navigator-widget.js +210 -0
- package/lib/browser/navigator-widget.js.map +1 -0
- package/lib/browser/open-editors-widget/navigator-deleted-editor-decorator.d.ts +16 -0
- package/lib/browser/open-editors-widget/navigator-deleted-editor-decorator.d.ts.map +1 -0
- package/lib/browser/open-editors-widget/navigator-deleted-editor-decorator.js +105 -0
- package/lib/browser/open-editors-widget/navigator-deleted-editor-decorator.js.map +1 -0
- package/lib/browser/open-editors-widget/navigator-open-editors-commands.d.ts +8 -0
- package/lib/browser/open-editors-widget/navigator-open-editors-commands.d.ts.map +1 -0
- package/lib/browser/open-editors-widget/navigator-open-editors-commands.js +48 -0
- package/lib/browser/open-editors-widget/navigator-open-editors-commands.js.map +1 -0
- package/lib/browser/open-editors-widget/navigator-open-editors-decorator-service.d.ts +8 -0
- package/lib/browser/open-editors-widget/navigator-open-editors-decorator-service.d.ts.map +1 -0
- package/lib/browser/open-editors-widget/navigator-open-editors-decorator-service.js +37 -0
- package/lib/browser/open-editors-widget/navigator-open-editors-decorator-service.js.map +1 -0
- package/lib/browser/open-editors-widget/navigator-open-editors-menus.d.ts +10 -0
- package/lib/browser/open-editors-widget/navigator-open-editors-menus.d.ts.map +1 -0
- package/lib/browser/open-editors-widget/navigator-open-editors-menus.js +28 -0
- package/lib/browser/open-editors-widget/navigator-open-editors-menus.js.map +1 -0
- package/lib/browser/open-editors-widget/navigator-open-editors-tree-model.d.ts +39 -0
- package/lib/browser/open-editors-widget/navigator-open-editors-tree-model.d.ts.map +1 -0
- package/lib/browser/open-editors-widget/navigator-open-editors-tree-model.js +251 -0
- package/lib/browser/open-editors-widget/navigator-open-editors-tree-model.js.map +1 -0
- package/lib/browser/open-editors-widget/navigator-open-editors-widget.d.ts +46 -0
- package/lib/browser/open-editors-widget/navigator-open-editors-widget.d.ts.map +1 -0
- package/lib/browser/open-editors-widget/navigator-open-editors-widget.js +225 -0
- package/lib/browser/open-editors-widget/navigator-open-editors-widget.js.map +1 -0
- package/lib/common/navigator-preferences.d.ts +15 -0
- package/lib/common/navigator-preferences.d.ts.map +1 -0
- package/lib/common/navigator-preferences.js +58 -0
- package/lib/common/navigator-preferences.js.map +1 -0
- package/lib/electron-browser/electron-navigator-menu-contribution.d.ts +22 -0
- package/lib/electron-browser/electron-navigator-menu-contribution.d.ts.map +1 -0
- package/lib/electron-browser/electron-navigator-menu-contribution.js +120 -0
- package/lib/electron-browser/electron-navigator-menu-contribution.js.map +1 -0
- package/lib/electron-browser/electron-navigator-module.d.ts +4 -0
- package/lib/electron-browser/electron-navigator-module.d.ts.map +1 -0
- package/lib/electron-browser/electron-navigator-module.js +27 -0
- package/lib/electron-browser/electron-navigator-module.js.map +1 -0
- package/lib/node/navigator-backend-module.d.ts +4 -0
- package/lib/node/navigator-backend-module.d.ts.map +1 -0
- package/lib/node/navigator-backend-module.js +23 -0
- package/lib/node/navigator-backend-module.js.map +1 -0
- package/lib/package.spec.d.ts +1 -0
- package/lib/package.spec.d.ts.map +1 -0
- package/lib/package.spec.js +26 -0
- package/lib/package.spec.js.map +1 -0
- package/package.json +5 -5
|
@@ -0,0 +1,210 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// *****************************************************************************
|
|
3
|
+
// Copyright (C) 2017 TypeFox and others.
|
|
4
|
+
//
|
|
5
|
+
// This program and the accompanying materials are made available under the
|
|
6
|
+
// terms of the Eclipse Public License v. 2.0 which is available at
|
|
7
|
+
// http://www.eclipse.org/legal/epl-2.0.
|
|
8
|
+
//
|
|
9
|
+
// This Source Code may also be made available under the following Secondary
|
|
10
|
+
// Licenses when the conditions for such availability set forth in the Eclipse
|
|
11
|
+
// Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
12
|
+
// with the GNU Classpath Exception which is available at
|
|
13
|
+
// https://www.gnu.org/software/classpath/license.html.
|
|
14
|
+
//
|
|
15
|
+
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
16
|
+
// *****************************************************************************
|
|
17
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
+
exports.FileNavigatorWidget = exports.CLASS = exports.LABEL = exports.FILE_NAVIGATOR_ID = void 0;
|
|
19
|
+
const tslib_1 = require("tslib");
|
|
20
|
+
const inversify_1 = require("@theia/core/shared/inversify");
|
|
21
|
+
const uri_1 = require("@theia/core/lib/common/uri");
|
|
22
|
+
const common_1 = require("@theia/core/lib/common");
|
|
23
|
+
const browser_1 = require("@theia/core/lib/browser");
|
|
24
|
+
const browser_2 = require("@theia/filesystem/lib/browser");
|
|
25
|
+
const browser_3 = require("@theia/workspace/lib/browser");
|
|
26
|
+
const navigator_tree_1 = require("./navigator-tree");
|
|
27
|
+
const navigator_model_1 = require("./navigator-model");
|
|
28
|
+
const core_1 = require("@theia/core");
|
|
29
|
+
const React = require("@theia/core/shared/react");
|
|
30
|
+
const navigator_context_key_service_1 = require("./navigator-context-key-service");
|
|
31
|
+
const nls_1 = require("@theia/core/lib/common/nls");
|
|
32
|
+
const abstract_navigator_tree_widget_1 = require("./abstract-navigator-tree-widget");
|
|
33
|
+
exports.FILE_NAVIGATOR_ID = 'files';
|
|
34
|
+
exports.LABEL = nls_1.nls.localizeByDefault('No Folder Opened');
|
|
35
|
+
exports.CLASS = 'theia-Files';
|
|
36
|
+
let FileNavigatorWidget = class FileNavigatorWidget extends abstract_navigator_tree_widget_1.AbstractNavigatorTreeWidget {
|
|
37
|
+
constructor(props, model, contextMenuRenderer) {
|
|
38
|
+
super(props, model, contextMenuRenderer);
|
|
39
|
+
this.model = model;
|
|
40
|
+
this.canOpenWorkspaceFileAndFolder = core_1.isOSX || !core_1.environment.electron.is();
|
|
41
|
+
this.openWorkspace = () => this.doOpenWorkspace();
|
|
42
|
+
this.openFolder = () => this.doOpenFolder();
|
|
43
|
+
this.addFolder = () => this.doAddFolder();
|
|
44
|
+
this.keyUpHandler = (e) => {
|
|
45
|
+
if (browser_1.Key.ENTER.keyCode === e.keyCode) {
|
|
46
|
+
e.target.click();
|
|
47
|
+
}
|
|
48
|
+
};
|
|
49
|
+
this.id = exports.FILE_NAVIGATOR_ID;
|
|
50
|
+
this.addClass(exports.CLASS);
|
|
51
|
+
}
|
|
52
|
+
init() {
|
|
53
|
+
super.init();
|
|
54
|
+
// This ensures that the context menu command to hide this widget receives the label 'Folders'
|
|
55
|
+
// regardless of the name of workspace. See ViewContainer.updateToolbarItems.
|
|
56
|
+
const dataset = { ...this.title.dataset, visibilityCommandLabel: nls_1.nls.localizeByDefault('Folders') };
|
|
57
|
+
this.title.dataset = dataset;
|
|
58
|
+
this.updateSelectionContextKeys();
|
|
59
|
+
this.toDispose.pushAll([
|
|
60
|
+
this.model.onSelectionChanged(() => this.updateSelectionContextKeys()),
|
|
61
|
+
this.model.onExpansionChanged(node => {
|
|
62
|
+
if (node.expanded && node.children.length === 1) {
|
|
63
|
+
const child = node.children[0];
|
|
64
|
+
if (browser_1.ExpandableTreeNode.is(child) && !child.expanded) {
|
|
65
|
+
this.model.expandNode(child);
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
})
|
|
69
|
+
]);
|
|
70
|
+
}
|
|
71
|
+
doUpdateRows() {
|
|
72
|
+
super.doUpdateRows();
|
|
73
|
+
this.title.label = exports.LABEL;
|
|
74
|
+
if (navigator_tree_1.WorkspaceNode.is(this.model.root)) {
|
|
75
|
+
if (this.model.root.name === navigator_tree_1.WorkspaceNode.name) {
|
|
76
|
+
const rootNode = this.model.root.children[0];
|
|
77
|
+
if (navigator_tree_1.WorkspaceRootNode.is(rootNode)) {
|
|
78
|
+
this.title.label = this.toNodeName(rootNode);
|
|
79
|
+
this.title.caption = this.labelProvider.getLongName(rootNode.uri);
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
else {
|
|
83
|
+
this.title.label = this.toNodeName(this.model.root);
|
|
84
|
+
this.title.caption = this.title.label;
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
else {
|
|
88
|
+
this.title.caption = this.title.label;
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
getContainerTreeNode() {
|
|
92
|
+
const root = this.model.root;
|
|
93
|
+
if (this.workspaceService.isMultiRootWorkspaceOpened) {
|
|
94
|
+
return root;
|
|
95
|
+
}
|
|
96
|
+
if (navigator_tree_1.WorkspaceNode.is(root)) {
|
|
97
|
+
return root.children[0];
|
|
98
|
+
}
|
|
99
|
+
return undefined;
|
|
100
|
+
}
|
|
101
|
+
renderTree(model) {
|
|
102
|
+
if (this.model.root && this.isEmptyMultiRootWorkspace(model)) {
|
|
103
|
+
return this.renderEmptyMultiRootWorkspace();
|
|
104
|
+
}
|
|
105
|
+
return super.renderTree(model);
|
|
106
|
+
}
|
|
107
|
+
shouldShowWelcomeView() {
|
|
108
|
+
return this.model.root === undefined;
|
|
109
|
+
}
|
|
110
|
+
onAfterAttach(msg) {
|
|
111
|
+
super.onAfterAttach(msg);
|
|
112
|
+
this.addClipboardListener(this.node, 'copy', e => this.handleCopy(e));
|
|
113
|
+
this.addClipboardListener(this.node, 'paste', e => this.handlePaste(e));
|
|
114
|
+
}
|
|
115
|
+
handleCopy(event) {
|
|
116
|
+
const uris = this.model.selectedFileStatNodes.map(node => node.uri.toString());
|
|
117
|
+
if (uris.length > 0 && event.clipboardData) {
|
|
118
|
+
event.clipboardData.setData('text/plain', uris.join('\n'));
|
|
119
|
+
event.preventDefault();
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
handlePaste(event) {
|
|
123
|
+
if (event.clipboardData) {
|
|
124
|
+
const raw = event.clipboardData.getData('text/plain');
|
|
125
|
+
if (!raw) {
|
|
126
|
+
return;
|
|
127
|
+
}
|
|
128
|
+
const target = this.model.selectedFileStatNodes[0];
|
|
129
|
+
if (!target) {
|
|
130
|
+
return;
|
|
131
|
+
}
|
|
132
|
+
for (const file of raw.split('\n')) {
|
|
133
|
+
event.preventDefault();
|
|
134
|
+
const source = new uri_1.default(file);
|
|
135
|
+
this.model.copy(source, target);
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
doOpenWorkspace() {
|
|
140
|
+
this.commandService.executeCommand(browser_3.WorkspaceCommands.OPEN_WORKSPACE.id);
|
|
141
|
+
}
|
|
142
|
+
doOpenFolder() {
|
|
143
|
+
this.commandService.executeCommand(browser_3.WorkspaceCommands.OPEN_FOLDER.id);
|
|
144
|
+
}
|
|
145
|
+
doAddFolder() {
|
|
146
|
+
this.commandService.executeCommand(browser_3.WorkspaceCommands.ADD_FOLDER.id);
|
|
147
|
+
}
|
|
148
|
+
/**
|
|
149
|
+
* When a multi-root workspace is opened, a user can remove all the folders from it.
|
|
150
|
+
* Instead of displaying an empty navigator tree, this will show a button to add more folders.
|
|
151
|
+
*/
|
|
152
|
+
renderEmptyMultiRootWorkspace() {
|
|
153
|
+
return React.createElement("div", { className: 'theia-navigator-container' },
|
|
154
|
+
React.createElement("div", { className: 'center' }, nls_1.nls.localizeByDefault('You have not yet added a folder to the workspace.\n{0}', '')),
|
|
155
|
+
React.createElement("div", { className: 'open-workspace-button-container' },
|
|
156
|
+
React.createElement("button", { className: 'theia-button open-workspace-button', title: nls_1.nls.localizeByDefault('Add Folder to Workspace'), onClick: this.addFolder, onKeyUp: this.keyUpHandler }, nls_1.nls.localizeByDefault('Open Folder'))));
|
|
157
|
+
}
|
|
158
|
+
isEmptyMultiRootWorkspace(model) {
|
|
159
|
+
return navigator_tree_1.WorkspaceNode.is(model.root) && model.root.children.length === 0;
|
|
160
|
+
}
|
|
161
|
+
tapNode(node) {
|
|
162
|
+
if (node && this.corePreferences['workbench.list.openMode'] === 'singleClick') {
|
|
163
|
+
this.model.previewNode(node);
|
|
164
|
+
}
|
|
165
|
+
super.tapNode(node);
|
|
166
|
+
}
|
|
167
|
+
onAfterShow(msg) {
|
|
168
|
+
super.onAfterShow(msg);
|
|
169
|
+
this.contextKeyService.explorerViewletVisible.set(true);
|
|
170
|
+
}
|
|
171
|
+
onAfterHide(msg) {
|
|
172
|
+
super.onAfterHide(msg);
|
|
173
|
+
this.contextKeyService.explorerViewletVisible.set(false);
|
|
174
|
+
}
|
|
175
|
+
updateSelectionContextKeys() {
|
|
176
|
+
this.contextKeyService.explorerResourceIsFolder.set(browser_2.DirNode.is(this.model.selectedNodes[0]));
|
|
177
|
+
// As `FileStatNode` only created if `FileService.resolve` was successful, we can safely assume that
|
|
178
|
+
// a valid `FileSystemProvider` is available for the selected node. So we skip an additional check
|
|
179
|
+
// for provider availability here and check the node type.
|
|
180
|
+
this.contextKeyService.isFileSystemResource.set(browser_2.FileStatNodeData.is(this.model.selectedNodes[0]));
|
|
181
|
+
}
|
|
182
|
+
};
|
|
183
|
+
exports.FileNavigatorWidget = FileNavigatorWidget;
|
|
184
|
+
tslib_1.__decorate([
|
|
185
|
+
(0, inversify_1.inject)(common_1.CommandService),
|
|
186
|
+
tslib_1.__metadata("design:type", Object)
|
|
187
|
+
], FileNavigatorWidget.prototype, "commandService", void 0);
|
|
188
|
+
tslib_1.__decorate([
|
|
189
|
+
(0, inversify_1.inject)(navigator_context_key_service_1.NavigatorContextKeyService),
|
|
190
|
+
tslib_1.__metadata("design:type", navigator_context_key_service_1.NavigatorContextKeyService)
|
|
191
|
+
], FileNavigatorWidget.prototype, "contextKeyService", void 0);
|
|
192
|
+
tslib_1.__decorate([
|
|
193
|
+
(0, inversify_1.inject)(browser_3.WorkspaceService),
|
|
194
|
+
tslib_1.__metadata("design:type", browser_3.WorkspaceService)
|
|
195
|
+
], FileNavigatorWidget.prototype, "workspaceService", void 0);
|
|
196
|
+
tslib_1.__decorate([
|
|
197
|
+
(0, inversify_1.postConstruct)(),
|
|
198
|
+
tslib_1.__metadata("design:type", Function),
|
|
199
|
+
tslib_1.__metadata("design:paramtypes", []),
|
|
200
|
+
tslib_1.__metadata("design:returntype", void 0)
|
|
201
|
+
], FileNavigatorWidget.prototype, "init", null);
|
|
202
|
+
exports.FileNavigatorWidget = FileNavigatorWidget = tslib_1.__decorate([
|
|
203
|
+
(0, inversify_1.injectable)(),
|
|
204
|
+
tslib_1.__param(0, (0, inversify_1.inject)(browser_1.TreeProps)),
|
|
205
|
+
tslib_1.__param(1, (0, inversify_1.inject)(navigator_model_1.FileNavigatorModel)),
|
|
206
|
+
tslib_1.__param(2, (0, inversify_1.inject)(browser_1.ContextMenuRenderer)),
|
|
207
|
+
tslib_1.__metadata("design:paramtypes", [Object, navigator_model_1.FileNavigatorModel,
|
|
208
|
+
browser_1.ContextMenuRenderer])
|
|
209
|
+
], FileNavigatorWidget);
|
|
210
|
+
//# sourceMappingURL=navigator-widget.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"navigator-widget.js","sourceRoot":"","sources":["../../src/browser/navigator-widget.tsx"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;;;AAEhF,4DAAiF;AAEjF,oDAA6C;AAC7C,mDAAwD;AACxD,qDAAuH;AACvH,2DAA0E;AAC1E,0DAAmF;AACnF,qDAAoE;AACpE,uDAAuD;AACvD,sCAAiD;AACjD,kDAAkD;AAClD,mFAA6E;AAC7E,oDAAiD;AACjD,qFAA+E;AAElE,QAAA,iBAAiB,GAAG,OAAO,CAAC;AAC5B,QAAA,KAAK,GAAG,SAAG,CAAC,iBAAiB,CAAC,kBAAkB,CAAC,CAAC;AAClD,QAAA,KAAK,GAAG,aAAa,CAAC;AAG5B,IAAM,mBAAmB,GAAzB,MAAM,mBAAoB,SAAQ,4DAA2B;IAMhE,YACuB,KAAgB,EACP,KAA2C,EAC1C,mBAAwC;QAErE,KAAK,CAAC,KAAK,EAAE,K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IAC7D,CAAC;IAES,0BAA0B;QAChC,IAAI,CAAC,iBAAiB,CAAC,wBAAwB,CAAC,GAAG,CAAC,iBAAO,CAAC,EAAE,CAAC,IAAI,CAAC,KAAK,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAC7F,oGAAoG;QACpG,kGAAkG;QAClG,0DAA0D;QAC1D,IAAI,CAAC,iBAAiB,CAAC,oBAAoB,CAAC,GAAG,CAAC,0BAAgB,CAAC,EAAE,CAAC,IAAI,CAAC,KAAK,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;IACtG,CAAC;CAEJ,CAAA;AAtLY,kDAAmB;AAEe;IAA1C,IAAA,kBAAM,EAAC,uBAAc,CAAC;;2DAAmD;AACnB;IAAtD,IAAA,kBAAM,EAAC,0DAA0B,CAAC;sCAAuC,0DAA0B;8DAAC;AACxD;IAA5C,IAAA,kBAAM,EAAC,0BAAgB,CAAC;sCAAsC,0BAAgB;6DAAC;AAa7D;IADlB,IAAA,yBAAa,GAAE;;;;+CAsBf;8BAtCQ,mBAAmB;IAD/B,IAAA,sBAAU,GAAE;IAQJ,mBAAA,IAAA,kBAAM,EAAC,mBAAS,CAAC,CAAA;IACjB,mBAAA,IAAA,kBAAM,EAAC,oCAAkB,CAAC,CAAA;IAC1B,mBAAA,IAAA,kBAAM,EAAC,6BAAmB,CAAC,CAAA;qDADyB,oCAAkB;QACrB,6BAAmB;GAThE,mBAAmB,CAsL/B"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { ApplicationShell, Tree, TreeDecoration, TreeDecorator } from '@theia/core/lib/browser';
|
|
2
|
+
import { FileSystemFrontendContribution } from '@theia/filesystem/lib/browser/filesystem-frontend-contribution';
|
|
3
|
+
import { Emitter } from '@theia/core';
|
|
4
|
+
export declare class NavigatorDeletedEditorDecorator implements TreeDecorator {
|
|
5
|
+
protected readonly fileSystemContribution: FileSystemFrontendContribution;
|
|
6
|
+
protected readonly shell: ApplicationShell;
|
|
7
|
+
readonly id = "theia-deleted-editor-decorator";
|
|
8
|
+
protected readonly onDidChangeDecorationsEmitter: Emitter<any>;
|
|
9
|
+
readonly onDidChangeDecorations: import("@theia/core").Event<any>;
|
|
10
|
+
protected deletedURIs: Set<string>;
|
|
11
|
+
init(): void;
|
|
12
|
+
decorations(tree: Tree): Map<string, TreeDecoration.Data>;
|
|
13
|
+
protected collectDecorators(tree: Tree): Map<string, TreeDecoration.Data>;
|
|
14
|
+
protected fireDidChangeDecorations(event: (tree: Tree) => Map<string, TreeDecoration.Data>): void;
|
|
15
|
+
}
|
|
16
|
+
//# sourceMappingURL=navigator-deleted-editor-decorator.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"navigator-deleted-editor-decorator.d.ts","sourceRoot":"","sources":["../../../src/browser/open-editors-widget/navigator-deleted-editor-decorator.ts"],"names":[],"mappings":"AAiBA,OAAO,EAAE,gBAAgB,EAA6C,IAAI,EAAE,cAAc,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAC3I,OAAO,EAAE,8BAA8B,EAAE,MAAM,gEAAgE,CAAC;AAChH,OAAO,EAAE,OAAO,EAAE,MAAM,aAAa,CAAC;AAItC,qBACa,+BAAgC,YAAW,aAAa;IAGjE,SAAS,CAAC,QAAQ,CAAC,sBAAsB,EAAE,8BAA8B,CAAC;IAE1E,SAAS,CAAC,QAAQ,CAAC,KAAK,EAAE,gBAAgB,CAAC;IAE3C,QAAQ,CAAC,EAAE,oCAAoC;IAC/C,SAAS,CAAC,QAAQ,CAAC,6BAA6B,eAAiB;IACjE,QAAQ,CAAC,sBAAsB,mCAA4C;IAC3E,SAAS,CAAC,WAAW,cAAqB;IAG1C,IAAI,IAAI,IAAI;IA0BZ,WAAW,CAAC,IAAI,EAAE,IAAI,GAAG,GAAG,CAAC,MAAM,EAAE,cAAc,CAAC,IAAI,CAAC;IAIzD,SAAS,CAAC,iBAAiB,CAAC,IAAI,EAAE,IAAI,GAAG,GAAG,CAAC,MAAM,EAAE,cAAc,CAAC,IAAI,CAAC;IAqBzE,SAAS,CAAC,wBAAwB,CAAC,KAAK,EAAE,CAAC,IAAI,EAAE,IAAI,KAAK,GAAG,CAAC,MAAM,EAAE,cAAc,CAAC,IAAI,CAAC,GAAG,IAAI;CAGpG"}
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// *****************************************************************************
|
|
3
|
+
// Copyright (C) 2021 Ericsson and others.
|
|
4
|
+
//
|
|
5
|
+
// This program and the accompanying materials are made available under the
|
|
6
|
+
// terms of the Eclipse Public License v. 2.0 which is available at
|
|
7
|
+
// http://www.eclipse.org/legal/epl-2.0.
|
|
8
|
+
//
|
|
9
|
+
// This Source Code may also be made available under the following Secondary
|
|
10
|
+
// Licenses when the conditions for such availability set forth in the Eclipse
|
|
11
|
+
// Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
12
|
+
// with the GNU Classpath Exception which is available at
|
|
13
|
+
// https://www.gnu.org/software/classpath/license.html.
|
|
14
|
+
//
|
|
15
|
+
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
16
|
+
// *****************************************************************************
|
|
17
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
+
exports.NavigatorDeletedEditorDecorator = void 0;
|
|
19
|
+
const tslib_1 = require("tslib");
|
|
20
|
+
const inversify_1 = require("@theia/core/shared/inversify");
|
|
21
|
+
const browser_1 = require("@theia/core/lib/browser");
|
|
22
|
+
const filesystem_frontend_contribution_1 = require("@theia/filesystem/lib/browser/filesystem-frontend-contribution");
|
|
23
|
+
const core_1 = require("@theia/core");
|
|
24
|
+
const browser_2 = require("@theia/filesystem/lib/browser");
|
|
25
|
+
let NavigatorDeletedEditorDecorator = class NavigatorDeletedEditorDecorator {
|
|
26
|
+
constructor() {
|
|
27
|
+
this.id = 'theia-deleted-editor-decorator';
|
|
28
|
+
this.onDidChangeDecorationsEmitter = new core_1.Emitter();
|
|
29
|
+
this.onDidChangeDecorations = this.onDidChangeDecorationsEmitter.event;
|
|
30
|
+
this.deletedURIs = new Set();
|
|
31
|
+
}
|
|
32
|
+
init() {
|
|
33
|
+
this.fileSystemContribution.onDidChangeEditorFile(({ editor, type }) => {
|
|
34
|
+
var _a;
|
|
35
|
+
const uri = (_a = editor.getResourceUri()) === null || _a === void 0 ? void 0 : _a.toString();
|
|
36
|
+
if (uri) {
|
|
37
|
+
if (type === 2 /* FileChangeType.DELETED */) {
|
|
38
|
+
this.deletedURIs.add(uri);
|
|
39
|
+
}
|
|
40
|
+
else if (type === 1 /* FileChangeType.ADDED */) {
|
|
41
|
+
this.deletedURIs.delete(uri);
|
|
42
|
+
}
|
|
43
|
+
this.fireDidChangeDecorations((tree) => this.collectDecorators(tree));
|
|
44
|
+
}
|
|
45
|
+
});
|
|
46
|
+
this.shell.onDidAddWidget(() => {
|
|
47
|
+
const newDeletedURIs = new Set();
|
|
48
|
+
this.shell.widgets.forEach(widget => {
|
|
49
|
+
var _a;
|
|
50
|
+
if (browser_1.NavigatableWidget.is(widget)) {
|
|
51
|
+
const uri = (_a = widget.getResourceUri()) === null || _a === void 0 ? void 0 : _a.toString();
|
|
52
|
+
if (uri && this.deletedURIs.has(uri)) {
|
|
53
|
+
newDeletedURIs.add(uri);
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
});
|
|
57
|
+
this.deletedURIs = newDeletedURIs;
|
|
58
|
+
});
|
|
59
|
+
}
|
|
60
|
+
decorations(tree) {
|
|
61
|
+
return this.collectDecorators(tree);
|
|
62
|
+
}
|
|
63
|
+
collectDecorators(tree) {
|
|
64
|
+
const result = new Map();
|
|
65
|
+
if (tree.root === undefined) {
|
|
66
|
+
return result;
|
|
67
|
+
}
|
|
68
|
+
for (const node of new browser_1.DepthFirstTreeIterator(tree.root)) {
|
|
69
|
+
if (browser_2.FileStatNode.is(node)) {
|
|
70
|
+
const uri = node.uri.toString();
|
|
71
|
+
if (this.deletedURIs.has(uri)) {
|
|
72
|
+
const deletedDecoration = {
|
|
73
|
+
fontData: {
|
|
74
|
+
style: 'line-through',
|
|
75
|
+
}
|
|
76
|
+
};
|
|
77
|
+
result.set(node.id, deletedDecoration);
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
return result;
|
|
82
|
+
}
|
|
83
|
+
fireDidChangeDecorations(event) {
|
|
84
|
+
this.onDidChangeDecorationsEmitter.fire(event);
|
|
85
|
+
}
|
|
86
|
+
};
|
|
87
|
+
exports.NavigatorDeletedEditorDecorator = NavigatorDeletedEditorDecorator;
|
|
88
|
+
tslib_1.__decorate([
|
|
89
|
+
(0, inversify_1.inject)(filesystem_frontend_contribution_1.FileSystemFrontendContribution),
|
|
90
|
+
tslib_1.__metadata("design:type", filesystem_frontend_contribution_1.FileSystemFrontendContribution)
|
|
91
|
+
], NavigatorDeletedEditorDecorator.prototype, "fileSystemContribution", void 0);
|
|
92
|
+
tslib_1.__decorate([
|
|
93
|
+
(0, inversify_1.inject)(browser_1.ApplicationShell),
|
|
94
|
+
tslib_1.__metadata("design:type", browser_1.ApplicationShell)
|
|
95
|
+
], NavigatorDeletedEditorDecorator.prototype, "shell", void 0);
|
|
96
|
+
tslib_1.__decorate([
|
|
97
|
+
(0, inversify_1.postConstruct)(),
|
|
98
|
+
tslib_1.__metadata("design:type", Function),
|
|
99
|
+
tslib_1.__metadata("design:paramtypes", []),
|
|
100
|
+
tslib_1.__metadata("design:returntype", void 0)
|
|
101
|
+
], NavigatorDeletedEditorDecorator.prototype, "init", null);
|
|
102
|
+
exports.NavigatorDeletedEditorDecorator = NavigatorDeletedEditorDecorator = tslib_1.__decorate([
|
|
103
|
+
(0, inversify_1.injectable)()
|
|
104
|
+
], NavigatorDeletedEditorDecorator);
|
|
105
|
+
//# sourceMappingURL=navigator-deleted-editor-decorator.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"navigator-deleted-editor-decorator.js","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,EAAE,EAAE,iBAAiB,CAAC,CAAC;gBAC3C,CAAC;YACL,CAAC;QACL,CAAC;QACD,OAAO,MAAM,CAAC;IAClB,CAAC;IAES,wBAAwB,CAAC,KAAuD;QACtF,IAAI,CAAC,6BAA6B,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;IACnD,CAAC;CACJ,CAAA;AAnEY,0EAA+B;AAGrB;IADlB,IAAA,kBAAM,EAAC,iEAA8B,CAAC;sCACI,iEAA8B;+EAAC;AAEvD;IADlB,IAAA,kBAAM,EAAC,0BAAgB,CAAC;sCACC,0BAAgB;8DAAC;AAQ3C;IADC,IAAA,yBAAa,GAAE;;;;2DAyBf;0CArCQ,+BAA+B;IAD3C,IAAA,sBAAU,GAAE;GACA,+BAA+B,CAmE3C"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Command } from '@theia/core/lib/common';
|
|
2
|
+
export declare namespace OpenEditorsCommands {
|
|
3
|
+
const CLOSE_ALL_TABS_FROM_TOOLBAR: Command;
|
|
4
|
+
const SAVE_ALL_TABS_FROM_TOOLBAR: Command;
|
|
5
|
+
const CLOSE_ALL_EDITORS_IN_GROUP_FROM_ICON: Command;
|
|
6
|
+
const SAVE_ALL_IN_GROUP_FROM_ICON: Command;
|
|
7
|
+
}
|
|
8
|
+
//# sourceMappingURL=navigator-open-editors-commands.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"navigator-open-editors-commands.d.ts","sourceRoot":"","sources":["../../../src/browser/open-editors-widget/navigator-open-editors-commands.ts"],"names":[],"mappings":"AAiBA,OAAO,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAC;AAEjD,yBAAiB,mBAAmB,CAAC;IAC1B,MAAM,2BAA2B,SAKtC,CAAC;IAEI,MAAM,0BAA0B,SAKrC,CAAC;IAEI,MAAM,oCAAoC,SAK/C,CAAC;IAEI,MAAM,2BAA2B,SAKtC,CAAC;CACN"}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// *****************************************************************************
|
|
3
|
+
// Copyright (C) 2021 Ericsson and others.
|
|
4
|
+
//
|
|
5
|
+
// This program and the accompanying materials are made available under the
|
|
6
|
+
// terms of the Eclipse Public License v. 2.0 which is available at
|
|
7
|
+
// http://www.eclipse.org/legal/epl-2.0.
|
|
8
|
+
//
|
|
9
|
+
// This Source Code may also be made available under the following Secondary
|
|
10
|
+
// Licenses when the conditions for such availability set forth in the Eclipse
|
|
11
|
+
// Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
12
|
+
// with the GNU Classpath Exception which is available at
|
|
13
|
+
// https://www.gnu.org/software/classpath/license.html.
|
|
14
|
+
//
|
|
15
|
+
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
16
|
+
// *****************************************************************************
|
|
17
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
+
exports.OpenEditorsCommands = void 0;
|
|
19
|
+
const browser_1 = require("@theia/core/lib/browser");
|
|
20
|
+
const common_1 = require("@theia/core/lib/common");
|
|
21
|
+
var OpenEditorsCommands;
|
|
22
|
+
(function (OpenEditorsCommands) {
|
|
23
|
+
OpenEditorsCommands.CLOSE_ALL_TABS_FROM_TOOLBAR = common_1.Command.toDefaultLocalizedCommand({
|
|
24
|
+
id: 'navigator.close.all.editors.toolbar',
|
|
25
|
+
category: browser_1.CommonCommands.FILE_CATEGORY,
|
|
26
|
+
label: 'Close All Editors',
|
|
27
|
+
iconClass: 'codicon codicon-close-all'
|
|
28
|
+
});
|
|
29
|
+
OpenEditorsCommands.SAVE_ALL_TABS_FROM_TOOLBAR = common_1.Command.toDefaultLocalizedCommand({
|
|
30
|
+
id: 'navigator.save.all.editors.toolbar',
|
|
31
|
+
category: browser_1.CommonCommands.FILE_CATEGORY,
|
|
32
|
+
label: 'Save All',
|
|
33
|
+
iconClass: 'codicon codicon-save-all'
|
|
34
|
+
});
|
|
35
|
+
OpenEditorsCommands.CLOSE_ALL_EDITORS_IN_GROUP_FROM_ICON = common_1.Command.toDefaultLocalizedCommand({
|
|
36
|
+
id: 'navigator.close.all.in.area.icon',
|
|
37
|
+
category: browser_1.CommonCommands.VIEW_CATEGORY,
|
|
38
|
+
label: 'Close Group',
|
|
39
|
+
iconClass: 'codicon codicon-close-all'
|
|
40
|
+
});
|
|
41
|
+
OpenEditorsCommands.SAVE_ALL_IN_GROUP_FROM_ICON = common_1.Command.toDefaultLocalizedCommand({
|
|
42
|
+
id: 'navigator.save.all.in.area.icon',
|
|
43
|
+
category: browser_1.CommonCommands.FILE_CATEGORY,
|
|
44
|
+
label: 'Save All in Group',
|
|
45
|
+
iconClass: 'codicon codicon-save-all'
|
|
46
|
+
});
|
|
47
|
+
})(OpenEditorsCommands || (exports.OpenEditorsCommands = OpenEditorsCommands = {}));
|
|
48
|
+
//# sourceMappingURL=navigator-open-editors-commands.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"navigator-open-editors-commands.js","sourceRoot":"","sources":["../../../src/browser/open-editors-widget/navigator-open-editors-commands.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,0CAA0C;AAC1C,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;;AAEhF,qDAAyD;AACzD,mDAAiD;AAEjD,IAAiB,mBAAmB,CA4BnC;AA5BD,WAAiB,mBAAmB;IACnB,+CAA2B,GAAG,gBAAO,CAAC,yBAAyB,CAAC;QACzE,EAAE,EAAE,qCAAqC;QACzC,QAAQ,EAAE,wBAAc,CAAC,aAAa;QACtC,KAAK,EAAE,mBAAmB;QAC1B,SAAS,EAAE,2BAA2B;KACzC,CAAC,CAAC;IAEU,8CAA0B,GAAG,gBAAO,CAAC,yBAAyB,CAAC;QACxE,EAAE,EAAE,oCAAoC;QACxC,QAAQ,EAAE,wBAAc,CAAC,aAAa;QACtC,KAAK,EAAE,UAAU;QACjB,SAAS,EAAE,0BAA0B;KACxC,CAAC,CAAC;IAEU,wDAAoC,GAAG,gBAAO,CAAC,yBAAyB,CAAC;QAClF,EAAE,EAAE,kCAAkC;QACtC,QAAQ,EAAE,wBAAc,CAAC,aAAa;QACtC,KAAK,EAAE,aAAa;QACpB,SAAS,EAAE,2BAA2B;KACzC,CAAC,CAAC;IAEU,+CAA2B,GAAG,gBAAO,CAAC,yBAAyB,CAAC;QACzE,EAAE,EAAE,iCAAiC;QACrC,QAAQ,EAAE,wBAAc,CAAC,aAAa;QACtC,KAAK,EAAE,mBAAmB;QAC1B,SAAS,EAAE,0BAA0B;KACxC,CAAC,CAAC;AACP,CAAC,EA5BgB,mBAAmB,mCAAnB,mBAAmB,QA4BnC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { TreeDecorator, AbstractTreeDecoratorService } from '@theia/core/lib/browser/tree/tree-decorator';
|
|
2
|
+
import { ContributionProvider } from '@theia/core/lib/common';
|
|
3
|
+
export declare const OpenEditorsTreeDecorator: unique symbol;
|
|
4
|
+
export declare class OpenEditorsTreeDecoratorService extends AbstractTreeDecoratorService {
|
|
5
|
+
protected readonly contributions: ContributionProvider<TreeDecorator>;
|
|
6
|
+
constructor(contributions: ContributionProvider<TreeDecorator>);
|
|
7
|
+
}
|
|
8
|
+
//# sourceMappingURL=navigator-open-editors-decorator-service.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"navigator-open-editors-decorator-service.d.ts","sourceRoot":"","sources":["../../../src/browser/open-editors-widget/navigator-open-editors-decorator-service.ts"],"names":[],"mappings":"AAiBA,OAAO,EAAE,aAAa,EAAE,4BAA4B,EAAE,MAAM,6CAA6C,CAAC;AAC1G,OAAO,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AAE9D,eAAO,MAAM,wBAAwB,eAAqC,CAAC;AAE3E,qBACa,+BAAgC,SAAQ,4BAA4B;IACF,SAAS,CAAC,QAAQ,CAAC,aAAa,EAAE,oBAAoB,CAAC,aAAa,CAAC;gBAAlD,aAAa,EAAE,oBAAoB,CAAC,aAAa,CAAC;CAGnJ"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// *****************************************************************************
|
|
3
|
+
// Copyright (C) 2021 Ericsson and others.
|
|
4
|
+
//
|
|
5
|
+
// This program and the accompanying materials are made available under the
|
|
6
|
+
// terms of the Eclipse Public License v. 2.0 which is available at
|
|
7
|
+
// http://www.eclipse.org/legal/epl-2.0.
|
|
8
|
+
//
|
|
9
|
+
// This Source Code may also be made available under the following Secondary
|
|
10
|
+
// Licenses when the conditions for such availability set forth in the Eclipse
|
|
11
|
+
// Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
12
|
+
// with the GNU Classpath Exception which is available at
|
|
13
|
+
// https://www.gnu.org/software/classpath/license.html.
|
|
14
|
+
//
|
|
15
|
+
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
16
|
+
// *****************************************************************************
|
|
17
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
+
exports.OpenEditorsTreeDecoratorService = exports.OpenEditorsTreeDecorator = void 0;
|
|
19
|
+
const tslib_1 = require("tslib");
|
|
20
|
+
const inversify_1 = require("@theia/core/shared/inversify");
|
|
21
|
+
const tree_decorator_1 = require("@theia/core/lib/browser/tree/tree-decorator");
|
|
22
|
+
const common_1 = require("@theia/core/lib/common");
|
|
23
|
+
exports.OpenEditorsTreeDecorator = Symbol('OpenEditorsTreeDecorator');
|
|
24
|
+
let OpenEditorsTreeDecoratorService = class OpenEditorsTreeDecoratorService extends tree_decorator_1.AbstractTreeDecoratorService {
|
|
25
|
+
constructor(contributions) {
|
|
26
|
+
super(contributions.getContributions());
|
|
27
|
+
this.contributions = contributions;
|
|
28
|
+
}
|
|
29
|
+
};
|
|
30
|
+
exports.OpenEditorsTreeDecoratorService = OpenEditorsTreeDecoratorService;
|
|
31
|
+
exports.OpenEditorsTreeDecoratorService = OpenEditorsTreeDecoratorService = tslib_1.__decorate([
|
|
32
|
+
(0, inversify_1.injectable)(),
|
|
33
|
+
tslib_1.__param(0, (0, inversify_1.inject)(common_1.ContributionProvider)),
|
|
34
|
+
tslib_1.__param(0, (0, inversify_1.named)(exports.OpenEditorsTreeDecorator)),
|
|
35
|
+
tslib_1.__metadata("design:paramtypes", [Object])
|
|
36
|
+
], OpenEditorsTreeDecoratorService);
|
|
37
|
+
//# sourceMappingURL=navigator-open-editors-decorator-service.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"navigator-open-editors-decorator-service.js","sourceRoot":"","sources":["../../../src/browser/open-editors-widget/navigator-open-editors-decorator-service.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,0CAA0C;AAC1C,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;;;AAEhF,4DAAyE;AACzE,gFAA0G;AAC1G,mDAA8D;AAEjD,QAAA,wBAAwB,GAAG,MAAM,CAAC,0BAA0B,CAAC,CAAC;AAGpE,IAAM,+BAA+B,GAArC,MAAM,+BAAgC,SAAQ,6CAA4B;IAC7E,YAA8F,aAAkD;QAC5I,KAAK,CAAC,aAAa,CAAC,gBAAgB,EAAE,CAAC,CAAC;QADkD,kBAAa,GAAb,aAAa,CAAqC;IAEhJ,CAAC;CACJ,CAAA;AAJY,0EAA+B;0CAA/B,+BAA+B;IAD3C,IAAA,sBAAU,GAAE;IAEI,mBAAA,IAAA,kBAAM,EAAC,6BAAoB,CAAC,CAAA;IAAE,mBAAA,IAAA,iBAAK,EAAC,gCAAwB,CAAC,CAAA;;GADjE,+BAA+B,CAI3C"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { MenuPath } from '@theia/core/lib/common';
|
|
2
|
+
export declare const OPEN_EDITORS_CONTEXT_MENU: MenuPath;
|
|
3
|
+
export declare namespace OpenEditorsContextMenu {
|
|
4
|
+
const NAVIGATION: string[];
|
|
5
|
+
const CLIPBOARD: string[];
|
|
6
|
+
const SAVE: string[];
|
|
7
|
+
const COMPARE: string[];
|
|
8
|
+
const MODIFICATION: string[];
|
|
9
|
+
}
|
|
10
|
+
//# sourceMappingURL=navigator-open-editors-menus.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"navigator-open-editors-menus.d.ts","sourceRoot":"","sources":["../../../src/browser/open-editors-widget/navigator-open-editors-menus.ts"],"names":[],"mappings":"AAgBA,OAAO,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAElD,eAAO,MAAM,yBAAyB,EAAE,QAAwC,CAAC;AACjF,yBAAiB,sBAAsB,CAAC;IAC7B,MAAM,UAAU,UAAiD,CAAC;IAClE,MAAM,SAAS,UAAgD,CAAC;IAChE,MAAM,IAAI,UAA2C,CAAC;IACtD,MAAM,OAAO,UAA8C,CAAC;IAC5D,MAAM,YAAY,UAAmD,CAAC;CAChF"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// *****************************************************************************
|
|
3
|
+
// Copyright (C) 2021 Ericsson and others.
|
|
4
|
+
//
|
|
5
|
+
// This program and the accompanying materials are made available under the
|
|
6
|
+
// terms of the Eclipse Public License v. 2.0 which is available at
|
|
7
|
+
// http://www.eclipse.org/legal/epl-2.0.
|
|
8
|
+
//
|
|
9
|
+
// This Source Code may also be made available under the following Secondary
|
|
10
|
+
// Licenses when the conditions for such availability set forth in the Eclipse
|
|
11
|
+
// Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
12
|
+
// with the GNU Classpath Exception which is available at
|
|
13
|
+
// https://www.gnu.org/software/classpath/license.html.
|
|
14
|
+
//
|
|
15
|
+
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
16
|
+
// *****************************************************************************
|
|
17
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
+
exports.OpenEditorsContextMenu = exports.OPEN_EDITORS_CONTEXT_MENU = void 0;
|
|
19
|
+
exports.OPEN_EDITORS_CONTEXT_MENU = ['open-editors-context-menu'];
|
|
20
|
+
var OpenEditorsContextMenu;
|
|
21
|
+
(function (OpenEditorsContextMenu) {
|
|
22
|
+
OpenEditorsContextMenu.NAVIGATION = [...exports.OPEN_EDITORS_CONTEXT_MENU, '1_navigation'];
|
|
23
|
+
OpenEditorsContextMenu.CLIPBOARD = [...exports.OPEN_EDITORS_CONTEXT_MENU, '2_clipboard'];
|
|
24
|
+
OpenEditorsContextMenu.SAVE = [...exports.OPEN_EDITORS_CONTEXT_MENU, '3_save'];
|
|
25
|
+
OpenEditorsContextMenu.COMPARE = [...exports.OPEN_EDITORS_CONTEXT_MENU, '4_compare'];
|
|
26
|
+
OpenEditorsContextMenu.MODIFICATION = [...exports.OPEN_EDITORS_CONTEXT_MENU, '5_modification'];
|
|
27
|
+
})(OpenEditorsContextMenu || (exports.OpenEditorsContextMenu = OpenEditorsContextMenu = {}));
|
|
28
|
+
//# sourceMappingURL=navigator-open-editors-menus.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"navigator-open-editors-menus.js","sourceRoot":"","sources":["../../../src/browser/open-editors-widget/navigator-open-editors-menus.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,0CAA0C;AAC1C,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;;AAInE,QAAA,yBAAyB,GAAa,CAAC,2BAA2B,CAAC,CAAC;AACjF,IAAiB,sBAAsB,CAMtC;AAND,WAAiB,sBAAsB;IACtB,iCAAU,GAAG,CAAC,GAAG,iCAAyB,EAAE,cAAc,CAAC,CAAC;IAC5D,gCAAS,GAAG,CAAC,GAAG,iCAAyB,EAAE,aAAa,CAAC,CAAC;IAC1D,2BAAI,GAAG,CAAC,GAAG,iCAAyB,EAAE,QAAQ,CAAC,CAAC;IAChD,8BAAO,GAAG,CAAC,GAAG,iCAAyB,EAAE,WAAW,CAAC,CAAC;IACtD,mCAAY,GAAG,CAAC,GAAG,iCAAyB,EAAE,gBAAgB,CAAC,CAAC;AACjF,CAAC,EANgB,sBAAsB,sCAAtB,sBAAsB,QAMtC"}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/// <reference types="lodash" />
|
|
2
|
+
import { FileStatNode, FileTreeModel } from '@theia/filesystem/lib/browser';
|
|
3
|
+
import { ApplicationShell, CompositeTreeNode, NavigatableWidget, OpenerService, TreeNode, Widget, TabBar } from '@theia/core/lib/browser';
|
|
4
|
+
import { WorkspaceService } from '@theia/workspace/lib/browser';
|
|
5
|
+
import { DisposableCollection } from '@theia/core/lib/common';
|
|
6
|
+
import { FileStat } from '@theia/filesystem/lib/common/files';
|
|
7
|
+
export interface OpenEditorNode extends FileStatNode {
|
|
8
|
+
widget: Widget;
|
|
9
|
+
}
|
|
10
|
+
export declare namespace OpenEditorNode {
|
|
11
|
+
function is(node: unknown): node is OpenEditorNode;
|
|
12
|
+
}
|
|
13
|
+
export declare class OpenEditorsModel extends FileTreeModel {
|
|
14
|
+
static GROUP_NODE_ID_PREFIX: string;
|
|
15
|
+
static AREA_NODE_ID_PREFIX: string;
|
|
16
|
+
protected readonly applicationShell: ApplicationShell;
|
|
17
|
+
protected readonly workspaceService: WorkspaceService;
|
|
18
|
+
protected readonly openerService: OpenerService;
|
|
19
|
+
protected toDisposeOnPreviewWidgetReplaced: DisposableCollection;
|
|
20
|
+
protected _editorWidgetsByGroup: Map<number, {
|
|
21
|
+
widgets: NavigatableWidget[];
|
|
22
|
+
tabbar: TabBar<Widget>;
|
|
23
|
+
}>;
|
|
24
|
+
protected _editorWidgetsByArea: Map<ApplicationShell.Area, NavigatableWidget[]>;
|
|
25
|
+
protected _lastEditorWidgetsByArea: Map<ApplicationShell.Area, NavigatableWidget[]>;
|
|
26
|
+
protected cachedFileStats: Map<string, FileStat>;
|
|
27
|
+
get editorWidgets(): NavigatableWidget[];
|
|
28
|
+
getTabBarForGroup(id: number): TabBar<Widget> | undefined;
|
|
29
|
+
protected init(): void;
|
|
30
|
+
protected setupHandlers(): void;
|
|
31
|
+
protected initializeRoot(): Promise<void>;
|
|
32
|
+
protected updateOpenWidgets: import("lodash").DebouncedFunc<(layoutModifiedArea?: ApplicationShell.Area) => Promise<void>>;
|
|
33
|
+
protected doUpdateOpenWidgets(layoutModifiedArea?: ApplicationShell.Area): Promise<void>;
|
|
34
|
+
protected shouldRebuildTreeOnLayoutModified(area: ApplicationShell.Area): boolean;
|
|
35
|
+
protected tryCreateWidgetGroupMap(): Map<Widget, CompositeTreeNode>;
|
|
36
|
+
protected buildRootFromOpenedWidgets(widgetsByArea: Map<ApplicationShell.Area, NavigatableWidget[]>): Promise<CompositeTreeNode>;
|
|
37
|
+
protected doOpenNode(node: TreeNode): void;
|
|
38
|
+
}
|
|
39
|
+
//# sourceMappingURL=navigator-open-editors-tree-model.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"navigator-open-editors-tree-model.d.ts","sourceRoot":"","sources":["../../../src/browser/open-editors-widget/navigator-open-editors-tree-model.ts"],"names":[],"mappings":";AAiBA,OAAO,EAAY,YAAY,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;AACtF,OAAO,EACH,gBAAgB,EAChB,iBAAiB,EAEjB,iBAAiB,EACjB,aAAa,EAEb,QAAQ,EACR,MAAM,EAEN,MAAM,EACT,MAAM,yBAAyB,C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