@codingame/monaco-vscode-extensions-service-override 37.2.0 → 37.3.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 +3 -3
- package/vscode/src/vs/platform/extensionManagement/common/extensionManagementCLI.js +37 -37
- package/vscode/src/vs/workbench/api/browser/mainThreadAgentEditorComments.js +2 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadAuthentication.js +31 -31
- package/vscode/src/vs/workbench/api/browser/mainThreadBulkEdits.js +6 -6
- package/vscode/src/vs/workbench/api/browser/mainThreadCLICommands.js +2 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadComments.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadCustomEditors.js +2 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadDataChannels.js +8 -8
- package/vscode/src/vs/workbench/api/browser/mainThreadDebugService.js +6 -6
- package/vscode/src/vs/workbench/api/browser/mainThreadDecorations.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadDocumentContentProviders.js +3 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadDocumentDiff.js +4 -4
- package/vscode/src/vs/workbench/api/browser/mainThreadDocumentsAndEditors.js +7 -7
- package/vscode/src/vs/workbench/api/browser/mainThreadEditSessionIdentityParticipant.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadEditor.js +5 -5
- package/vscode/src/vs/workbench/api/browser/mainThreadEditors.js +10 -10
- package/vscode/src/vs/workbench/api/browser/mainThreadExtensionService.js +12 -12
- package/vscode/src/vs/workbench/api/browser/mainThreadFileSystem.js +2 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadFileSystemEventService.js +20 -20
- package/vscode/src/vs/workbench/api/browser/mainThreadGitExtensionService.js +4 -4
- package/vscode/src/vs/workbench/api/browser/mainThreadLanguageFeatures.js +15 -15
- package/vscode/src/vs/workbench/api/browser/mainThreadLanguages.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadMessageService.js +6 -6
- package/vscode/src/vs/workbench/api/browser/mainThreadOutputService.js +3 -3
- package/vscode/src/vs/workbench/api/browser/mainThreadProgress.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadQuickDiff.js +2 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadQuickOpen.js +3 -3
- package/vscode/src/vs/workbench/api/browser/mainThreadSCM.js +7 -7
- package/vscode/src/vs/workbench/api/browser/mainThreadSaveParticipant.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadSecretState.js +2 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadTask.js +2 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadTerminalService.d.ts +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadTerminalService.js +5 -5
- package/vscode/src/vs/workbench/api/browser/mainThreadTerminalShellIntegration.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadTesting.js +12 -6
- package/vscode/src/vs/workbench/api/browser/mainThreadTreeViews.js +13 -8
- package/vscode/src/vs/workbench/api/browser/mainThreadTunnelService.js +6 -6
- package/vscode/src/vs/workbench/api/browser/mainThreadUriOpeners.js +2 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadWebviews.js +2 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadWorkspace.js +14 -12
- package/vscode/src/vs/workbench/contrib/customEditor/common/customTextEditorModel.js +1 -1
- package/vscode/src/vs/workbench/services/extensionManagement/browser/extensionBisect.js +25 -25
- package/vscode/src/vs/workbench/services/extensionManagement/browser/webExtensionsScannerService.js +37 -32
- package/vscode/src/vs/workbench/services/extensions/browser/extensionService.js +18 -10
- package/vscode/src/vs/workbench/services/extensions/common/abstractExtensionService.js +55 -45
- package/vscode/src/vs/workbench/services/extensions/common/extensionHostManager.js +4 -4
- package/vscode/src/vs/workbench/services/extensions/common/extensionRunningLocationTracker.js +3 -1
- package/vscode/src/vs/workbench/services/extensions/common/extensionsProposedApi.js +4 -2
- package/vscode/src/vs/workbench/services/extensions/common/extensionsUtil.js +4 -4
- package/vscode/src/vs/workbench/services/extensions/common/lazyCreateExtensionHostManager.js +4 -2
- package/vscode/src/vs/workbench/services/themes/browser/cssExtensionPoint.js +5 -5
|
@@ -115,7 +115,7 @@ let MainThreadDebugService = class MainThreadDebugService {
|
|
|
115
115
|
id,
|
|
116
116
|
disposeDebugVisualizers: ids => this._proxy.$disposeDebugVisualizers(ids),
|
|
117
117
|
executeDebugVisualizerCommand: id => this._proxy.$executeDebugVisualizerCommand(id),
|
|
118
|
-
provideDebugVisualizers: (context, token) => this._proxy.$provideDebugVisualizers(extensionId, id, context, token).then(r =>
|
|
118
|
+
provideDebugVisualizers: (context, token) => this._proxy.$provideDebugVisualizers(extensionId, id, context, token).then(r => r.map(IDebugVisualization.deserialize)),
|
|
119
119
|
resolveDebugVisualizer: (viz, token) => this._proxy.$resolveDebugVisualizer(viz.id, token)
|
|
120
120
|
});
|
|
121
121
|
this._visualizerHandles.set(`${extensionId}/${id}`, handle);
|
|
@@ -133,7 +133,7 @@ let MainThreadDebugService = class MainThreadDebugService {
|
|
|
133
133
|
delta.added = this.convertToDto(e.added);
|
|
134
134
|
}
|
|
135
135
|
if (e.removed) {
|
|
136
|
-
delta.removed =
|
|
136
|
+
delta.removed = e.removed.map(x => x.getId());
|
|
137
137
|
}
|
|
138
138
|
if (e.changed) {
|
|
139
139
|
delta.changed = this.convertToDto(e.changed);
|
|
@@ -175,7 +175,7 @@ let MainThreadDebugService = class MainThreadDebugService {
|
|
|
175
175
|
$registerBreakpoints(DTOs) {
|
|
176
176
|
for (const dto of DTOs) {
|
|
177
177
|
if (dto.type === "sourceMulti") {
|
|
178
|
-
const rawbps =
|
|
178
|
+
const rawbps = dto.lines.map(l => ({
|
|
179
179
|
id: l.id,
|
|
180
180
|
enabled: l.enabled,
|
|
181
181
|
lineNumber: l.line + 1,
|
|
@@ -184,7 +184,7 @@ let MainThreadDebugService = class MainThreadDebugService {
|
|
|
184
184
|
hitCondition: l.hitCondition,
|
|
185
185
|
logMessage: l.logMessage,
|
|
186
186
|
mode: l.mode
|
|
187
|
-
}))
|
|
187
|
+
}));
|
|
188
188
|
this.debugService.addBreakpoints(URI.revive(dto.uri), rawbps);
|
|
189
189
|
} else if (dto.type === "function") {
|
|
190
190
|
this.debugService.addFunctionBreakpoint({
|
|
@@ -387,7 +387,7 @@ let MainThreadDebugService = class MainThreadDebugService {
|
|
|
387
387
|
return undefined;
|
|
388
388
|
}
|
|
389
389
|
convertToDto(bps) {
|
|
390
|
-
return
|
|
390
|
+
return bps.map(bp => {
|
|
391
391
|
if ("name" in bp) {
|
|
392
392
|
const fbp = bp;
|
|
393
393
|
return {
|
|
@@ -429,7 +429,7 @@ let MainThreadDebugService = class MainThreadDebugService {
|
|
|
429
429
|
} else {
|
|
430
430
|
return undefined;
|
|
431
431
|
}
|
|
432
|
-
})
|
|
432
|
+
}).filter(isDefined);
|
|
433
433
|
}
|
|
434
434
|
};
|
|
435
435
|
MainThreadDebugService = __decorate([extHostNamedCustomer(MainContext.MainThreadDebugService), ( __param(1, IDebugService)), ( __param(2, IDebugVisualizerService))], MainThreadDebugService);
|
|
@@ -89,7 +89,7 @@ let MainThreadDecorations = class MainThreadDecorations {
|
|
|
89
89
|
const provider = this._provider.get(handle);
|
|
90
90
|
if (provider) {
|
|
91
91
|
const [emitter] = provider;
|
|
92
|
-
emitter.fire(resources &&
|
|
92
|
+
emitter.fire(resources && resources.map(r => URI.revive(r)));
|
|
93
93
|
}
|
|
94
94
|
}
|
|
95
95
|
$unregisterDecorationProvider(handle) {
|
|
@@ -73,7 +73,9 @@ let MainThreadDocumentContentProviders = class MainThreadDocumentContentProvider
|
|
|
73
73
|
return;
|
|
74
74
|
}
|
|
75
75
|
if (edits && edits.length > 0) {
|
|
76
|
-
model.applyEdits(
|
|
76
|
+
model.applyEdits(
|
|
77
|
+
edits.map(edit => EditOperation.replace(Range.lift(edit.range), edit.text))
|
|
78
|
+
);
|
|
77
79
|
}
|
|
78
80
|
} catch (error) {
|
|
79
81
|
onUnexpectedError(error);
|
|
@@ -43,12 +43,12 @@ let MainThreadDocumentDiff = class MainThreadDocumentDiff {
|
|
|
43
43
|
return {
|
|
44
44
|
identical: result.identical,
|
|
45
45
|
quitEarly: result.quitEarly,
|
|
46
|
-
changes:
|
|
47
|
-
moves:
|
|
46
|
+
changes: result.changes.map(mapChange),
|
|
47
|
+
moves: result.moves.map(m => ({
|
|
48
48
|
originalRange: toLineRange(m.lineRangeMapping.original),
|
|
49
49
|
modifiedRange: toLineRange(m.lineRangeMapping.modified),
|
|
50
|
-
changes:
|
|
51
|
-
}))
|
|
50
|
+
changes: m.changes.map(mapChange)
|
|
51
|
+
}))
|
|
52
52
|
};
|
|
53
53
|
}
|
|
54
54
|
dispose() {}
|
|
@@ -53,10 +53,10 @@ class DocumentAndEditorStateDelta {
|
|
|
53
53
|
}
|
|
54
54
|
toString() {
|
|
55
55
|
let ret = "DocumentAndEditorStateDelta\n";
|
|
56
|
-
ret += `\tRemoved Documents: [${
|
|
57
|
-
ret += `\tAdded Documents: [${
|
|
58
|
-
ret += `\tRemoved Editors: [${
|
|
59
|
-
ret += `\tAdded Editors: [${
|
|
56
|
+
ret += `\tRemoved Documents: [${this.removedDocuments.map(d => ( d.uri.toString(true))).join(", ")}]\n`;
|
|
57
|
+
ret += `\tAdded Documents: [${this.addedDocuments.map(d => ( d.uri.toString(true))).join(", ")}]\n`;
|
|
58
|
+
ret += `\tRemoved Editors: [${this.removedEditors.map(e => e.id).join(", ")}]\n`;
|
|
59
|
+
ret += `\tAdded Editors: [${this.addedEditors.map(e => e.id).join(", ")}]\n`;
|
|
60
60
|
ret += `\tNew Active Editor: ${this.newActiveEditor}\n`;
|
|
61
61
|
return ret;
|
|
62
62
|
}
|
|
@@ -294,7 +294,7 @@ let MainThreadDocumentsAndEditors = class MainThreadDocumentsAndEditors extends
|
|
|
294
294
|
_onDelta(delta) {
|
|
295
295
|
const removedEditors = [];
|
|
296
296
|
const addedEditors = [];
|
|
297
|
-
const removedDocuments =
|
|
297
|
+
const removedDocuments = delta.removedDocuments.map(m => m.uri);
|
|
298
298
|
for (const apiEditor of delta.addedEditors) {
|
|
299
299
|
const mainThreadEditor = ( new MainThreadTextEditor(apiEditor.id, apiEditor.editor.getModel(), apiEditor.editor, {
|
|
300
300
|
onGainedFocus() {},
|
|
@@ -328,11 +328,11 @@ let MainThreadDocumentsAndEditors = class MainThreadDocumentsAndEditors extends
|
|
|
328
328
|
}
|
|
329
329
|
if (delta.addedDocuments.length > 0) {
|
|
330
330
|
empty = false;
|
|
331
|
-
extHostDelta.addedDocuments =
|
|
331
|
+
extHostDelta.addedDocuments = delta.addedDocuments.map(m => this._toModelAddData(m));
|
|
332
332
|
}
|
|
333
333
|
if (delta.addedEditors.length > 0) {
|
|
334
334
|
empty = false;
|
|
335
|
-
extHostDelta.addedEditors =
|
|
335
|
+
extHostDelta.addedEditors = addedEditors.map(e => this._toTextEditorAddData(e));
|
|
336
336
|
}
|
|
337
337
|
if (!empty) {
|
|
338
338
|
this._proxy.$acceptDocumentsAndEditorsDelta(extHostDelta);
|
|
@@ -14,7 +14,7 @@ class ExtHostEditSessionIdentityCreateParticipant {
|
|
|
14
14
|
}
|
|
15
15
|
async participate(workspaceFolder, token) {
|
|
16
16
|
const p = ( new Promise((resolve, reject) => {
|
|
17
|
-
setTimeout(() => reject(( new Error(( localize(
|
|
17
|
+
setTimeout(() => reject(( new Error(( localize(4953, "Aborted onWillCreateEditSessionIdentity-event after 10000ms"))))), this.timeout);
|
|
18
18
|
this._proxy.$onWillCreateEditSessionIdentity(workspaceFolder.uri, token, this.timeout).then(resolve, reject);
|
|
19
19
|
}));
|
|
20
20
|
return raceCancellationError(p, token);
|
|
@@ -247,7 +247,7 @@ class MainThreadTextEditor {
|
|
|
247
247
|
this._codeEditor.setSelections(selections);
|
|
248
248
|
return;
|
|
249
249
|
}
|
|
250
|
-
const newSelections =
|
|
250
|
+
const newSelections = selections.map(Selection.liftSelection);
|
|
251
251
|
this._setProperties(( new MainThreadTextEditorProperties(newSelections, this._properties.options, this._properties.visibleRanges)), null);
|
|
252
252
|
}
|
|
253
253
|
_setIndentConfiguration(newConfiguration) {
|
|
@@ -371,13 +371,13 @@ class MainThreadTextEditor {
|
|
|
371
371
|
if (typeof opts.setEndOfLine !== "undefined") {
|
|
372
372
|
this._model.pushEOL(opts.setEndOfLine);
|
|
373
373
|
}
|
|
374
|
-
const transformedEdits =
|
|
374
|
+
const transformedEdits = edits.map(edit => {
|
|
375
375
|
return {
|
|
376
376
|
range: Range.lift(edit.range),
|
|
377
377
|
text: edit.text,
|
|
378
378
|
forceMoveMarkers: edit.forceMoveMarkers
|
|
379
379
|
};
|
|
380
|
-
})
|
|
380
|
+
});
|
|
381
381
|
if (opts.undoStopBefore) {
|
|
382
382
|
this._codeEditor.pushUndoStop();
|
|
383
383
|
}
|
|
@@ -408,10 +408,10 @@ class MainThreadTextEditor {
|
|
|
408
408
|
return false;
|
|
409
409
|
}
|
|
410
410
|
this._codeEditor.focus();
|
|
411
|
-
const edits =
|
|
411
|
+
const edits = ranges.map(range => ({
|
|
412
412
|
range: Range.lift(range),
|
|
413
413
|
template
|
|
414
|
-
}))
|
|
414
|
+
}));
|
|
415
415
|
snippetController.apply(edits, {
|
|
416
416
|
overwriteBefore: 0,
|
|
417
417
|
overwriteAfter: 0,
|
|
@@ -133,11 +133,11 @@ let MainThreadTextEditors = class MainThreadTextEditors {
|
|
|
133
133
|
}
|
|
134
134
|
toDispose.push(quickDiffModelRef);
|
|
135
135
|
return observableFromEvent(this, quickDiffModelRef.object.onDidChange, () => {
|
|
136
|
-
return
|
|
136
|
+
return quickDiffModelRef.object.getQuickDiffResults().map(result => ({
|
|
137
137
|
original: result.original,
|
|
138
138
|
modified: result.modified,
|
|
139
139
|
changes: result.changes2
|
|
140
|
-
}))
|
|
140
|
+
}));
|
|
141
141
|
});
|
|
142
142
|
}
|
|
143
143
|
const diffAlgorithm = this._configurationService.getValue("diffEditor.diffAlgorithm");
|
|
@@ -155,13 +155,13 @@ let MainThreadTextEditors = class MainThreadTextEditors {
|
|
|
155
155
|
const diffInformation = [{
|
|
156
156
|
original: editorModel.original.uri,
|
|
157
157
|
modified: editorModel.modified.uri,
|
|
158
|
-
changes:
|
|
158
|
+
changes: diffChanges.map(change => change)
|
|
159
159
|
}];
|
|
160
|
-
const quickDiffInformation =
|
|
160
|
+
const quickDiffInformation = quickDiffModelRef.object.getQuickDiffResults().filter(result => result.providerKind !== "primary").map(result => ({
|
|
161
161
|
original: result.original,
|
|
162
162
|
modified: result.modified,
|
|
163
163
|
changes: result.changes2
|
|
164
|
-
}))
|
|
164
|
+
}));
|
|
165
165
|
return diffInformation.concat(quickDiffInformation);
|
|
166
166
|
}
|
|
167
167
|
);
|
|
@@ -180,20 +180,20 @@ let MainThreadTextEditors = class MainThreadTextEditors {
|
|
|
180
180
|
return undefined;
|
|
181
181
|
}
|
|
182
182
|
const documentVersion = isITextModel(editorModel) ? editorModel.getVersionId() : editorModel.modified.getVersionId();
|
|
183
|
-
return
|
|
184
|
-
const changes =
|
|
183
|
+
return editorChanges.map(change => {
|
|
184
|
+
const changes = change.changes.map(change => [
|
|
185
185
|
change.original.startLineNumber,
|
|
186
186
|
change.original.endLineNumberExclusive,
|
|
187
187
|
change.modified.startLineNumber,
|
|
188
188
|
change.modified.endLineNumberExclusive
|
|
189
|
-
])
|
|
189
|
+
]);
|
|
190
190
|
return {
|
|
191
191
|
documentVersion,
|
|
192
192
|
original: change.original,
|
|
193
193
|
modified: change.modified,
|
|
194
194
|
changes
|
|
195
195
|
};
|
|
196
|
-
})
|
|
196
|
+
});
|
|
197
197
|
});
|
|
198
198
|
}
|
|
199
199
|
async $tryShowTextDocument(resource, options) {
|
|
@@ -338,7 +338,7 @@ let MainThreadTextEditors = class MainThreadTextEditors {
|
|
|
338
338
|
try {
|
|
339
339
|
const primaryQuickDiff = quickDiffModelRef.object.quickDiffs.find(quickDiff => quickDiff.kind === "primary");
|
|
340
340
|
const primaryQuickDiffChanges = quickDiffModelRef.object.changes.filter(change => change.providerId === primaryQuickDiff?.id);
|
|
341
|
-
return Promise.resolve(
|
|
341
|
+
return Promise.resolve(primaryQuickDiffChanges.map(change => change.change) ?? []);
|
|
342
342
|
} finally {
|
|
343
343
|
quickDiffModelRef.dispose();
|
|
344
344
|
}
|
|
@@ -46,7 +46,7 @@ let MainThreadExtensionService = class MainThreadExtensionService {
|
|
|
46
46
|
const internalExtHostContext = extHostContext;
|
|
47
47
|
this._internalExtensionService = internalExtHostContext.internalExtensionService;
|
|
48
48
|
internalExtHostContext._setExtensionHostProxy(( new ExtensionHostProxy(( extHostContext.getProxy(ExtHostContext.ExtHostExtensionService)))));
|
|
49
|
-
internalExtHostContext._setAllMainProxyIdentifiers((
|
|
49
|
+
internalExtHostContext._setAllMainProxyIdentifiers(( Object.keys(MainContext)).map(key => MainContext[key]));
|
|
50
50
|
}
|
|
51
51
|
dispose() {}
|
|
52
52
|
$getExtension(extensionId) {
|
|
@@ -111,7 +111,7 @@ let MainThreadExtensionService = class MainThreadExtensionService {
|
|
|
111
111
|
this._notificationService.notify({
|
|
112
112
|
severity: Severity.Error,
|
|
113
113
|
message: ( localize(
|
|
114
|
-
|
|
114
|
+
4954,
|
|
115
115
|
"Cannot activate the '{0}' extension because it depends on the '{1}' extension, which is not loaded. Would you like to reload the window to load the extension?",
|
|
116
116
|
extName,
|
|
117
117
|
missingInstalledDependency.manifest.displayName || missingInstalledDependency.manifest.name
|
|
@@ -119,7 +119,7 @@ let MainThreadExtensionService = class MainThreadExtensionService {
|
|
|
119
119
|
actions: {
|
|
120
120
|
primary: [toAction({
|
|
121
121
|
id: "reload",
|
|
122
|
-
label: ( localize(
|
|
122
|
+
label: ( localize(4955, "Reload Window")),
|
|
123
123
|
run: () => this._hostService.reload()
|
|
124
124
|
})]
|
|
125
125
|
}
|
|
@@ -130,7 +130,7 @@ let MainThreadExtensionService = class MainThreadExtensionService {
|
|
|
130
130
|
this._notificationService.notify({
|
|
131
131
|
severity: Severity.Error,
|
|
132
132
|
message: ( localize(
|
|
133
|
-
|
|
133
|
+
4956,
|
|
134
134
|
"Cannot activate the '{0}' extension because it depends on the '{1}' extension which is not supported in the current workspace",
|
|
135
135
|
extName,
|
|
136
136
|
missingInstalledDependency.manifest.displayName || missingInstalledDependency.manifest.name
|
|
@@ -140,7 +140,7 @@ let MainThreadExtensionService = class MainThreadExtensionService {
|
|
|
140
140
|
this._notificationService.notify({
|
|
141
141
|
severity: Severity.Error,
|
|
142
142
|
message: ( localize(
|
|
143
|
-
|
|
143
|
+
4957,
|
|
144
144
|
"Cannot activate the '{0}' extension because it depends on the '{1}' extension which is not supported in Restricted Mode",
|
|
145
145
|
extName,
|
|
146
146
|
missingInstalledDependency.manifest.displayName || missingInstalledDependency.manifest.name
|
|
@@ -148,7 +148,7 @@ let MainThreadExtensionService = class MainThreadExtensionService {
|
|
|
148
148
|
actions: {
|
|
149
149
|
primary: [toAction({
|
|
150
150
|
id: "manageWorkspaceTrust",
|
|
151
|
-
label: ( localize(
|
|
151
|
+
label: ( localize(4958, "Manage Workspace Trust")),
|
|
152
152
|
run: () => this._commandService.executeCommand("workbench.trust.manage")
|
|
153
153
|
})]
|
|
154
154
|
}
|
|
@@ -157,7 +157,7 @@ let MainThreadExtensionService = class MainThreadExtensionService {
|
|
|
157
157
|
this._notificationService.notify({
|
|
158
158
|
severity: Severity.Error,
|
|
159
159
|
message: ( localize(
|
|
160
|
-
|
|
160
|
+
4959,
|
|
161
161
|
"Cannot activate the '{0}' extension because it depends on the '{1}' extension which is disabled. Would you like to enable the extension and reload the window?",
|
|
162
162
|
extName,
|
|
163
163
|
missingInstalledDependency.manifest.displayName || missingInstalledDependency.manifest.name
|
|
@@ -165,7 +165,7 @@ let MainThreadExtensionService = class MainThreadExtensionService {
|
|
|
165
165
|
actions: {
|
|
166
166
|
primary: [toAction({
|
|
167
167
|
id: "enable",
|
|
168
|
-
label: ( localize(
|
|
168
|
+
label: ( localize(4960, "Enable and Reload")),
|
|
169
169
|
enabled: true,
|
|
170
170
|
run: () => this._extensionEnablementService.setEnablement(
|
|
171
171
|
[missingInstalledDependency],
|
|
@@ -178,7 +178,7 @@ let MainThreadExtensionService = class MainThreadExtensionService {
|
|
|
178
178
|
this._notificationService.notify({
|
|
179
179
|
severity: Severity.Error,
|
|
180
180
|
message: ( localize(
|
|
181
|
-
|
|
181
|
+
4961,
|
|
182
182
|
"Cannot activate the '{0}' extension because it depends on the '{1}' extension which is disabled.",
|
|
183
183
|
extName,
|
|
184
184
|
missingInstalledDependency.manifest.displayName || missingInstalledDependency.manifest.name
|
|
@@ -199,7 +199,7 @@ let MainThreadExtensionService = class MainThreadExtensionService {
|
|
|
199
199
|
this._notificationService.notify({
|
|
200
200
|
severity: Severity.Error,
|
|
201
201
|
message: ( localize(
|
|
202
|
-
|
|
202
|
+
4962,
|
|
203
203
|
"Cannot activate the '{0}' extension because it depends on the '{1}' extension from '{2}', which is not installed. Would you like to install the extension and reload the window?",
|
|
204
204
|
extName,
|
|
205
205
|
dependencyExtension.displayName,
|
|
@@ -208,14 +208,14 @@ let MainThreadExtensionService = class MainThreadExtensionService {
|
|
|
208
208
|
actions: {
|
|
209
209
|
primary: [toAction({
|
|
210
210
|
id: "install",
|
|
211
|
-
label: ( localize(
|
|
211
|
+
label: ( localize(4963, "Install and Reload")),
|
|
212
212
|
run: () => this._extensionsWorkbenchService.install(dependencyExtension).then(() => this._hostService.reload(), e => this._notificationService.error(e))
|
|
213
213
|
})]
|
|
214
214
|
}
|
|
215
215
|
});
|
|
216
216
|
} else {
|
|
217
217
|
this._notificationService.error(( localize(
|
|
218
|
-
|
|
218
|
+
4964,
|
|
219
219
|
"Cannot activate the '{0}' extension because it depends on an unknown '{1}' extension.",
|
|
220
220
|
extName,
|
|
221
221
|
missingDependency
|
|
@@ -84,7 +84,7 @@ let MainThreadFileSystem = MainThreadFileSystem_1 = class MainThreadFileSystem {
|
|
|
84
84
|
err.name = FileSystemProviderErrorCode.FileNotADirectory;
|
|
85
85
|
throw err;
|
|
86
86
|
}
|
|
87
|
-
return !stat.children ? [] :
|
|
87
|
+
return !stat.children ? [] : stat.children.map(child => [child.name, MainThreadFileSystem_1._asFileType(child)]);
|
|
88
88
|
} catch (err) {
|
|
89
89
|
return MainThreadFileSystem_1._handleError(err);
|
|
90
90
|
}
|
|
@@ -196,7 +196,7 @@ class RemoteFileSystemProvider {
|
|
|
196
196
|
});
|
|
197
197
|
}
|
|
198
198
|
$onFileSystemChange(changes) {
|
|
199
|
-
this._onDidChange.fire(
|
|
199
|
+
this._onDidChange.fire(changes.map(RemoteFileSystemProvider._createFileChange));
|
|
200
200
|
}
|
|
201
201
|
static _createFileChange(dto) {
|
|
202
202
|
return {
|
|
@@ -94,25 +94,25 @@ let MainThreadFileSystemEventService = class MainThreadFileSystemEventService {
|
|
|
94
94
|
if (data.extensionNames.length === 1) {
|
|
95
95
|
if (operation === FileOperation.CREATE) {
|
|
96
96
|
message = ( localize(
|
|
97
|
-
|
|
97
|
+
4965,
|
|
98
98
|
"Extension '{0}' wants to make refactoring changes with this file creation",
|
|
99
99
|
data.extensionNames[0]
|
|
100
100
|
));
|
|
101
101
|
} else if (operation === FileOperation.COPY) {
|
|
102
102
|
message = ( localize(
|
|
103
|
-
|
|
103
|
+
4966,
|
|
104
104
|
"Extension '{0}' wants to make refactoring changes with this file copy",
|
|
105
105
|
data.extensionNames[0]
|
|
106
106
|
));
|
|
107
107
|
} else if (operation === FileOperation.MOVE) {
|
|
108
108
|
message = ( localize(
|
|
109
|
-
|
|
109
|
+
4967,
|
|
110
110
|
"Extension '{0}' wants to make refactoring changes with this file move",
|
|
111
111
|
data.extensionNames[0]
|
|
112
112
|
));
|
|
113
113
|
} else {
|
|
114
114
|
message = ( localize(
|
|
115
|
-
|
|
115
|
+
4968,
|
|
116
116
|
"Extension '{0}' wants to make refactoring changes with this file deletion",
|
|
117
117
|
data.extensionNames[0]
|
|
118
118
|
));
|
|
@@ -120,25 +120,25 @@ let MainThreadFileSystemEventService = class MainThreadFileSystemEventService {
|
|
|
120
120
|
} else {
|
|
121
121
|
if (operation === FileOperation.CREATE) {
|
|
122
122
|
message = ( localize(
|
|
123
|
-
|
|
123
|
+
4969,
|
|
124
124
|
"{0} extensions want to make refactoring changes with this file creation",
|
|
125
125
|
data.extensionNames.length
|
|
126
126
|
));
|
|
127
127
|
} else if (operation === FileOperation.COPY) {
|
|
128
128
|
message = ( localize(
|
|
129
|
-
|
|
129
|
+
4970,
|
|
130
130
|
"{0} extensions want to make refactoring changes with this file copy",
|
|
131
131
|
data.extensionNames.length
|
|
132
132
|
));
|
|
133
133
|
} else if (operation === FileOperation.MOVE) {
|
|
134
134
|
message = ( localize(
|
|
135
|
-
|
|
135
|
+
4971,
|
|
136
136
|
"{0} extensions want to make refactoring changes with this file move",
|
|
137
137
|
data.extensionNames.length
|
|
138
138
|
));
|
|
139
139
|
} else {
|
|
140
140
|
message = ( localize(
|
|
141
|
-
|
|
141
|
+
4972,
|
|
142
142
|
"{0} extensions want to make refactoring changes with this file deletion",
|
|
143
143
|
data.extensionNames.length
|
|
144
144
|
));
|
|
@@ -150,8 +150,8 @@ let MainThreadFileSystemEventService = class MainThreadFileSystemEventService {
|
|
|
150
150
|
} = await dialogService.confirm({
|
|
151
151
|
type: Severity.Info,
|
|
152
152
|
message,
|
|
153
|
-
primaryButton: ( localize(
|
|
154
|
-
cancelButton: ( localize(
|
|
153
|
+
primaryButton: ( localize(4973, "Show &&Preview")),
|
|
154
|
+
cancelButton: ( localize(4974, "Skip Changes"))
|
|
155
155
|
});
|
|
156
156
|
showPreview = true;
|
|
157
157
|
if (!confirmed) {
|
|
@@ -171,18 +171,18 @@ let MainThreadFileSystemEventService = class MainThreadFileSystemEventService {
|
|
|
171
171
|
type: Severity.Info,
|
|
172
172
|
message,
|
|
173
173
|
buttons: [{
|
|
174
|
-
label: ( localize(
|
|
174
|
+
label: ( localize(4975, "&&OK")),
|
|
175
175
|
run: () => Choice.OK
|
|
176
176
|
}, {
|
|
177
|
-
label: ( localize(
|
|
177
|
+
label: ( localize(4973, "Show &&Preview")),
|
|
178
178
|
run: () => Choice.Preview
|
|
179
179
|
}],
|
|
180
180
|
cancelButton: {
|
|
181
|
-
label: ( localize(
|
|
181
|
+
label: ( localize(4974, "Skip Changes")),
|
|
182
182
|
run: () => Choice.Cancel
|
|
183
183
|
},
|
|
184
184
|
checkbox: {
|
|
185
|
-
label: ( localize(
|
|
185
|
+
label: ( localize(4976, "Do not ask me again"))
|
|
186
186
|
}
|
|
187
187
|
});
|
|
188
188
|
if (result === Choice.Cancel) {
|
|
@@ -211,15 +211,15 @@ let MainThreadFileSystemEventService = class MainThreadFileSystemEventService {
|
|
|
211
211
|
_progressLabel(operation) {
|
|
212
212
|
switch (operation) {
|
|
213
213
|
case FileOperation.CREATE:
|
|
214
|
-
return localize(
|
|
214
|
+
return localize(4977, "Running 'File Create' participants...");
|
|
215
215
|
case FileOperation.MOVE:
|
|
216
|
-
return localize(
|
|
216
|
+
return localize(4978, "Running 'File Rename' participants...");
|
|
217
217
|
case FileOperation.COPY:
|
|
218
|
-
return localize(
|
|
218
|
+
return localize(4979, "Running 'File Copy' participants...");
|
|
219
219
|
case FileOperation.DELETE:
|
|
220
|
-
return localize(
|
|
220
|
+
return localize(4980, "Running 'File Delete' participants...");
|
|
221
221
|
case FileOperation.WRITE:
|
|
222
|
-
return localize(
|
|
222
|
+
return localize(4981, "Running 'File Write' participants...");
|
|
223
223
|
}
|
|
224
224
|
}
|
|
225
225
|
})();
|
|
@@ -307,7 +307,7 @@ registerAction2(class ResetMemento extends Action2 {
|
|
|
307
307
|
super({
|
|
308
308
|
id: "files.participants.resetChoice",
|
|
309
309
|
title: {
|
|
310
|
-
value: ( localize(
|
|
310
|
+
value: ( localize(4982, "Reset choice for 'File operation needs preview'")),
|
|
311
311
|
original: `Reset choice for 'File operation needs preview'`
|
|
312
312
|
},
|
|
313
313
|
f1: true
|
|
@@ -110,10 +110,10 @@ let MainThreadGitExtensionService = class MainThreadGitExtensionService extends
|
|
|
110
110
|
if (token?.isCancellationRequested) {
|
|
111
111
|
return [];
|
|
112
112
|
}
|
|
113
|
-
return
|
|
113
|
+
return result.map(ref => ({
|
|
114
114
|
...ref,
|
|
115
115
|
type: toGitRefType(ref.type)
|
|
116
|
-
}))
|
|
116
|
+
}));
|
|
117
117
|
}
|
|
118
118
|
async diffBetweenWithStats(root, ref1, ref2, path) {
|
|
119
119
|
const handle = this._repositoryHandles.get(root);
|
|
@@ -121,7 +121,7 @@ let MainThreadGitExtensionService = class MainThreadGitExtensionService extends
|
|
|
121
121
|
return [];
|
|
122
122
|
}
|
|
123
123
|
const result = await this._proxy.$diffBetweenWithStats(handle, ref1, ref2, path);
|
|
124
|
-
return
|
|
124
|
+
return result.map(toGitDiffChange);
|
|
125
125
|
}
|
|
126
126
|
async diffBetweenWithStats2(root, ref, path) {
|
|
127
127
|
const handle = this._repositoryHandles.get(root);
|
|
@@ -129,7 +129,7 @@ let MainThreadGitExtensionService = class MainThreadGitExtensionService extends
|
|
|
129
129
|
return [];
|
|
130
130
|
}
|
|
131
131
|
const result = await this._proxy.$diffBetweenWithStats2(handle, ref, path);
|
|
132
|
-
return
|
|
132
|
+
return result.map(toGitDiffChange);
|
|
133
133
|
}
|
|
134
134
|
async $onDidChangeRepository(handle) {
|
|
135
135
|
const repository = this._repositories.get(handle);
|
|
@@ -299,7 +299,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
299
299
|
this._languageFeaturesService.multiDocumentHighlightProvider.register(selector, {
|
|
300
300
|
selector: selector,
|
|
301
301
|
provideMultiDocumentHighlights: (model, position, otherModels, token) => {
|
|
302
|
-
return this._proxy.$provideMultiDocumentHighlights(handle, model.uri, position,
|
|
302
|
+
return this._proxy.$provideMultiDocumentHighlights(handle, model.uri, position, otherModels.map(model => model.uri), token).then(dto => {
|
|
303
303
|
if (dto === undefined || dto === null) {
|
|
304
304
|
return undefined;
|
|
305
305
|
}
|
|
@@ -555,9 +555,9 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
555
555
|
return result;
|
|
556
556
|
}
|
|
557
557
|
return {
|
|
558
|
-
suggestions:
|
|
558
|
+
suggestions: result[ISuggestResultDtoField.completions].map(
|
|
559
559
|
d => MainThreadLanguageFeatures_1._inflateSuggestDto(result[ISuggestResultDtoField.defaultRanges], d, extensionId)
|
|
560
|
-
)
|
|
560
|
+
),
|
|
561
561
|
incomplete: result[ISuggestResultDtoField.isIncomplete] || false,
|
|
562
562
|
duration: result[ISuggestResultDtoField.duration],
|
|
563
563
|
dispose: () => {
|
|
@@ -728,7 +728,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
728
728
|
return undefined;
|
|
729
729
|
}
|
|
730
730
|
return {
|
|
731
|
-
links:
|
|
731
|
+
links: dto.links.map(MainThreadLanguageFeatures_1._reviveLinkDTO),
|
|
732
732
|
dispose: () => {
|
|
733
733
|
if (typeof dto.cacheId === "number") {
|
|
734
734
|
this._proxy.$releaseDocumentLinks(handle, dto.cacheId);
|
|
@@ -759,7 +759,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
759
759
|
this._registrations.set(handle, this._languageFeaturesService.colorProvider.register(selector, {
|
|
760
760
|
provideDocumentColors: (model, token) => {
|
|
761
761
|
return proxy.$provideDocumentColors(handle, model.uri, token).then(documentColors => {
|
|
762
|
-
return
|
|
762
|
+
return documentColors.map(documentColor => {
|
|
763
763
|
const [red, green, blue, alpha] = documentColor.color;
|
|
764
764
|
const color = {
|
|
765
765
|
red: red,
|
|
@@ -771,7 +771,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
771
771
|
color,
|
|
772
772
|
range: documentColor.range
|
|
773
773
|
};
|
|
774
|
-
})
|
|
774
|
+
});
|
|
775
775
|
});
|
|
776
776
|
},
|
|
777
777
|
provideColorPresentations: (model, colorInfo, token) => {
|
|
@@ -833,7 +833,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
833
833
|
this._proxy.$releaseCallHierarchy(handle, item._sessionId);
|
|
834
834
|
}
|
|
835
835
|
},
|
|
836
|
-
roots:
|
|
836
|
+
roots: items.map(MainThreadLanguageFeatures_1._reviveCallHierarchyItemDto)
|
|
837
837
|
};
|
|
838
838
|
},
|
|
839
839
|
provideOutgoingCalls: async (item, token) => {
|
|
@@ -878,7 +878,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
878
878
|
};
|
|
879
879
|
}
|
|
880
880
|
static _reviveOnEnterRules(onEnterRules) {
|
|
881
|
-
return
|
|
881
|
+
return onEnterRules.map(MainThreadLanguageFeatures_1._reviveOnEnterRule);
|
|
882
882
|
}
|
|
883
883
|
$setLanguageConfiguration(handle, languageId, _configuration) {
|
|
884
884
|
const configuration = {
|
|
@@ -924,7 +924,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
924
924
|
this._proxy.$releaseTypeHierarchy(handle, item._sessionId);
|
|
925
925
|
}
|
|
926
926
|
},
|
|
927
|
-
roots:
|
|
927
|
+
roots: items.map(MainThreadLanguageFeatures_1._reviveTypeHierarchyItemDto)
|
|
928
928
|
};
|
|
929
929
|
},
|
|
930
930
|
provideSupertypes: async (item, token) => {
|
|
@@ -932,14 +932,14 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
932
932
|
if (!supertypes) {
|
|
933
933
|
return supertypes;
|
|
934
934
|
}
|
|
935
|
-
return
|
|
935
|
+
return supertypes.map(MainThreadLanguageFeatures_1._reviveTypeHierarchyItemDto);
|
|
936
936
|
},
|
|
937
937
|
provideSubtypes: async (item, token) => {
|
|
938
938
|
const subtypes = await this._proxy.$provideTypeHierarchySubtypes(handle, item._sessionId, item._itemId, token);
|
|
939
939
|
if (!subtypes) {
|
|
940
940
|
return subtypes;
|
|
941
941
|
}
|
|
942
|
-
return
|
|
942
|
+
return subtypes.map(MainThreadLanguageFeatures_1._reviveTypeHierarchyItemDto);
|
|
943
943
|
}
|
|
944
944
|
}));
|
|
945
945
|
}
|
|
@@ -1010,7 +1010,7 @@ let MainThreadPasteEditProvider = class MainThreadPasteEditProvider {
|
|
|
1010
1010
|
return;
|
|
1011
1011
|
}
|
|
1012
1012
|
return {
|
|
1013
|
-
edits:
|
|
1013
|
+
edits: edits.map(edit => {
|
|
1014
1014
|
return {
|
|
1015
1015
|
...edit,
|
|
1016
1016
|
kind: edit.kind ? ( new HierarchicalKind(edit.kind.value)) : ( new HierarchicalKind("")),
|
|
@@ -1023,7 +1023,7 @@ let MainThreadPasteEditProvider = class MainThreadPasteEditProvider {
|
|
|
1023
1023
|
dataId => this.resolveFileData(request.id, dataId)
|
|
1024
1024
|
) : undefined
|
|
1025
1025
|
};
|
|
1026
|
-
})
|
|
1026
|
+
}),
|
|
1027
1027
|
dispose: () => {
|
|
1028
1028
|
this._proxy.$releasePasteEdits(this._handle, request.id);
|
|
1029
1029
|
}
|
|
@@ -1081,7 +1081,7 @@ let MainThreadDocumentOnDropEditProvider = class MainThreadDocumentOnDropEditPro
|
|
|
1081
1081
|
return;
|
|
1082
1082
|
}
|
|
1083
1083
|
return {
|
|
1084
|
-
edits:
|
|
1084
|
+
edits: edits.map(edit => {
|
|
1085
1085
|
return {
|
|
1086
1086
|
...edit,
|
|
1087
1087
|
yieldTo: edit.yieldTo?.map(x => ({
|
|
@@ -1094,7 +1094,7 @@ let MainThreadDocumentOnDropEditProvider = class MainThreadDocumentOnDropEditPro
|
|
|
1094
1094
|
dataId => this.resolveDocumentOnDropFileData(request.id, dataId)
|
|
1095
1095
|
)
|
|
1096
1096
|
};
|
|
1097
|
-
})
|
|
1097
|
+
}),
|
|
1098
1098
|
dispose: () => {
|
|
1099
1099
|
this._proxy.$releaseDocumentOnDropEdits(this._handle, request.id);
|
|
1100
1100
|
}
|