@codingame/monaco-vscode-api 1.67.5 → 1.67.6
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/dist/api.amd.js +34 -33
- package/dist/api.cjs +34 -33
- package/dist/api.js +34 -33
- package/package.json +1 -1
package/dist/api.amd.js
CHANGED
|
@@ -4639,7 +4639,7 @@ define(['exports', 'monaco-editor/esm/vs/base/common/errors.js', 'monaco-editor/
|
|
|
4639
4639
|
this._argumentProcessors.push(processor);
|
|
4640
4640
|
}
|
|
4641
4641
|
registerApiCommand(apiCommand) {
|
|
4642
|
-
const registration =
|
|
4642
|
+
const registration = this.registerCommand(false, apiCommand.id, async (...apiArgs) => {
|
|
4643
4643
|
const internalArgs = apiCommand.args.map((arg, i) => {
|
|
4644
4644
|
if (!arg.validate(apiArgs[i])) {
|
|
4645
4645
|
throw new Error(`Invalid argument '${arg.name}' when running '${apiCommand.id}', received: ${apiArgs[i]}`);
|
|
@@ -4821,6 +4821,7 @@ define(['exports', 'monaco-editor/esm/vs/base/common/errors.js', 'monaco-editor/
|
|
|
4821
4821
|
this.delegatingCommandId = `_vscode_delegate_cmd_${Date.now().toString(36)}`;
|
|
4822
4822
|
this._cache = /*#__PURE__*/ new Map();
|
|
4823
4823
|
this._cachIdPool = 0;
|
|
4824
|
+
this._commands.registerCommand(true, this.delegatingCommandId, this._executeConvertedCommand, this);
|
|
4824
4825
|
}
|
|
4825
4826
|
toInternal(command, disposables) {
|
|
4826
4827
|
if (!command) {
|
|
@@ -9907,7 +9908,7 @@ define(['exports', 'monaco-editor/esm/vs/base/common/errors.js', 'monaco-editor/
|
|
|
9907
9908
|
return data;
|
|
9908
9909
|
}
|
|
9909
9910
|
$registerDocumentSymbolProvider(handle, selector, displayName) {
|
|
9910
|
-
this._registrations.set(handle,
|
|
9911
|
+
this._registrations.set(handle, this._languageFeaturesService.documentSymbolProvider.register(selector, {
|
|
9911
9912
|
displayName,
|
|
9912
9913
|
provideDocumentSymbols: (model, token) => {
|
|
9913
9914
|
return this._proxy.$provideDocumentSymbols(handle, model.uri, token);
|
|
@@ -9935,7 +9936,7 @@ define(['exports', 'monaco-editor/esm/vs/base/common/errors.js', 'monaco-editor/
|
|
|
9935
9936
|
this._registrations.set(eventHandle, emitter);
|
|
9936
9937
|
provider.onDidChange = emitter.event;
|
|
9937
9938
|
}
|
|
9938
|
-
this._registrations.set(handle,
|
|
9939
|
+
this._registrations.set(handle, this._languageFeaturesService.codeLensProvider.register(selector, provider));
|
|
9939
9940
|
}
|
|
9940
9941
|
$emitCodeLensEvent(eventHandle, event) {
|
|
9941
9942
|
const obj = this._registrations.get(eventHandle);
|
|
@@ -9944,42 +9945,42 @@ define(['exports', 'monaco-editor/esm/vs/base/common/errors.js', 'monaco-editor/
|
|
|
9944
9945
|
}
|
|
9945
9946
|
}
|
|
9946
9947
|
$registerDefinitionSupport(handle, selector) {
|
|
9947
|
-
this._registrations.set(handle,
|
|
9948
|
+
this._registrations.set(handle, this._languageFeaturesService.definitionProvider.register(selector, {
|
|
9948
9949
|
provideDefinition: (model, position, token) => {
|
|
9949
9950
|
return this._proxy.$provideDefinition(handle, model.uri, position, token).then(MainThreadLanguageFeatures_1._reviveLocationLinkDto);
|
|
9950
9951
|
}
|
|
9951
9952
|
}));
|
|
9952
9953
|
}
|
|
9953
9954
|
$registerDeclarationSupport(handle, selector) {
|
|
9954
|
-
this._registrations.set(handle,
|
|
9955
|
+
this._registrations.set(handle, this._languageFeaturesService.declarationProvider.register(selector, {
|
|
9955
9956
|
provideDeclaration: (model, position, token) => {
|
|
9956
9957
|
return this._proxy.$provideDeclaration(handle, model.uri, position, token).then(MainThreadLanguageFeatures_1._reviveLocationLinkDto);
|
|
9957
9958
|
}
|
|
9958
9959
|
}));
|
|
9959
9960
|
}
|
|
9960
9961
|
$registerImplementationSupport(handle, selector) {
|
|
9961
|
-
this._registrations.set(handle,
|
|
9962
|
+
this._registrations.set(handle, this._languageFeaturesService.implementationProvider.register(selector, {
|
|
9962
9963
|
provideImplementation: (model, position, token) => {
|
|
9963
9964
|
return this._proxy.$provideImplementation(handle, model.uri, position, token).then(MainThreadLanguageFeatures_1._reviveLocationLinkDto);
|
|
9964
9965
|
}
|
|
9965
9966
|
}));
|
|
9966
9967
|
}
|
|
9967
9968
|
$registerTypeDefinitionSupport(handle, selector) {
|
|
9968
|
-
this._registrations.set(handle,
|
|
9969
|
+
this._registrations.set(handle, this._languageFeaturesService.typeDefinitionProvider.register(selector, {
|
|
9969
9970
|
provideTypeDefinition: (model, position, token) => {
|
|
9970
9971
|
return this._proxy.$provideTypeDefinition(handle, model.uri, position, token).then(MainThreadLanguageFeatures_1._reviveLocationLinkDto);
|
|
9971
9972
|
}
|
|
9972
9973
|
}));
|
|
9973
9974
|
}
|
|
9974
9975
|
$registerHoverProvider(handle, selector) {
|
|
9975
|
-
this._registrations.set(handle,
|
|
9976
|
+
this._registrations.set(handle, this._languageFeaturesService.hoverProvider.register(selector, {
|
|
9976
9977
|
provideHover: (model, position, token) => {
|
|
9977
9978
|
return this._proxy.$provideHover(handle, model.uri, position, token);
|
|
9978
9979
|
}
|
|
9979
9980
|
}));
|
|
9980
9981
|
}
|
|
9981
9982
|
$registerEvaluatableExpressionProvider(handle, selector) {
|
|
9982
|
-
this._registrations.set(handle,
|
|
9983
|
+
this._registrations.set(handle, this._languageFeaturesService.evaluatableExpressionProvider.register(selector, {
|
|
9983
9984
|
provideEvaluatableExpression: (model, position, token) => {
|
|
9984
9985
|
return this._proxy.$provideEvaluatableExpression(handle, model.uri, position, token);
|
|
9985
9986
|
}
|
|
@@ -9996,7 +9997,7 @@ define(['exports', 'monaco-editor/esm/vs/base/common/errors.js', 'monaco-editor/
|
|
|
9996
9997
|
this._registrations.set(eventHandle, emitter);
|
|
9997
9998
|
provider.onDidChangeInlineValues = emitter.event;
|
|
9998
9999
|
}
|
|
9999
|
-
this._registrations.set(handle,
|
|
10000
|
+
this._registrations.set(handle, this._languageFeaturesService.inlineValuesProvider.register(selector, provider));
|
|
10000
10001
|
}
|
|
10001
10002
|
$emitInlineValuesEvent(eventHandle, event) {
|
|
10002
10003
|
const obj = this._registrations.get(eventHandle);
|
|
@@ -10005,14 +10006,14 @@ define(['exports', 'monaco-editor/esm/vs/base/common/errors.js', 'monaco-editor/
|
|
|
10005
10006
|
}
|
|
10006
10007
|
}
|
|
10007
10008
|
$registerDocumentHighlightProvider(handle, selector) {
|
|
10008
|
-
this._registrations.set(handle,
|
|
10009
|
+
this._registrations.set(handle, this._languageFeaturesService.documentHighlightProvider.register(selector, {
|
|
10009
10010
|
provideDocumentHighlights: (model, position, token) => {
|
|
10010
10011
|
return this._proxy.$provideDocumentHighlights(handle, model.uri, position, token);
|
|
10011
10012
|
}
|
|
10012
10013
|
}));
|
|
10013
10014
|
}
|
|
10014
10015
|
$registerLinkedEditingRangeProvider(handle, selector) {
|
|
10015
|
-
this._registrations.set(handle,
|
|
10016
|
+
this._registrations.set(handle, this._languageFeaturesService.linkedEditingRangeProvider.register(selector, {
|
|
10016
10017
|
provideLinkedEditingRanges: async (model, position, token) => {
|
|
10017
10018
|
const res = await this._proxy.$provideLinkedEditingRanges(handle, model.uri, position, token);
|
|
10018
10019
|
if (res) {
|
|
@@ -10026,7 +10027,7 @@ define(['exports', 'monaco-editor/esm/vs/base/common/errors.js', 'monaco-editor/
|
|
|
10026
10027
|
}));
|
|
10027
10028
|
}
|
|
10028
10029
|
$registerReferenceSupport(handle, selector) {
|
|
10029
|
-
this._registrations.set(handle,
|
|
10030
|
+
this._registrations.set(handle, this._languageFeaturesService.referenceProvider.register(selector, {
|
|
10030
10031
|
provideReferences: (model, position, context, token) => {
|
|
10031
10032
|
return this._proxy.$provideReferences(handle, model.uri, position, context, token).then(MainThreadLanguageFeatures_1._reviveLocationDto);
|
|
10032
10033
|
}
|
|
@@ -10059,10 +10060,10 @@ define(['exports', 'monaco-editor/esm/vs/base/common/errors.js', 'monaco-editor/
|
|
|
10059
10060
|
return codeAction;
|
|
10060
10061
|
};
|
|
10061
10062
|
}
|
|
10062
|
-
this._registrations.set(handle,
|
|
10063
|
+
this._registrations.set(handle, this._languageFeaturesService.codeActionProvider.register(selector, provider));
|
|
10063
10064
|
}
|
|
10064
10065
|
$registerDocumentFormattingSupport(handle, selector, extensionId, displayName) {
|
|
10065
|
-
this._registrations.set(handle,
|
|
10066
|
+
this._registrations.set(handle, this._languageFeaturesService.documentFormattingEditProvider.register(selector, {
|
|
10066
10067
|
extensionId,
|
|
10067
10068
|
displayName,
|
|
10068
10069
|
provideDocumentFormattingEdits: (model, options, token) => {
|
|
@@ -10071,7 +10072,7 @@ define(['exports', 'monaco-editor/esm/vs/base/common/errors.js', 'monaco-editor/
|
|
|
10071
10072
|
}));
|
|
10072
10073
|
}
|
|
10073
10074
|
$registerRangeFormattingSupport(handle, selector, extensionId, displayName) {
|
|
10074
|
-
this._registrations.set(handle,
|
|
10075
|
+
this._registrations.set(handle, this._languageFeaturesService.documentRangeFormattingEditProvider.register(selector, {
|
|
10075
10076
|
extensionId,
|
|
10076
10077
|
displayName,
|
|
10077
10078
|
provideDocumentRangeFormattingEdits: (model, range, options, token) => {
|
|
@@ -10080,7 +10081,7 @@ define(['exports', 'monaco-editor/esm/vs/base/common/errors.js', 'monaco-editor/
|
|
|
10080
10081
|
}));
|
|
10081
10082
|
}
|
|
10082
10083
|
$registerOnTypeFormattingSupport(handle, selector, autoFormatTriggerCharacters, extensionId) {
|
|
10083
|
-
this._registrations.set(handle,
|
|
10084
|
+
this._registrations.set(handle, this._languageFeaturesService.onTypeFormattingEditProvider.register(selector, {
|
|
10084
10085
|
extensionId,
|
|
10085
10086
|
autoFormatTriggerCharacters,
|
|
10086
10087
|
provideOnTypeFormattingEdits: (model, position, ch, options, token) => {
|
|
@@ -10106,10 +10107,10 @@ define(['exports', 'monaco-editor/esm/vs/base/common/errors.js', 'monaco-editor/
|
|
|
10106
10107
|
return resolvedItem && MainThreadLanguageFeatures_1._reviveWorkspaceSymbolDto(resolvedItem);
|
|
10107
10108
|
};
|
|
10108
10109
|
}
|
|
10109
|
-
this._registrations.set(handle,
|
|
10110
|
+
this._registrations.set(handle, WorkspaceSymbolProviderRegistry.register(provider));
|
|
10110
10111
|
}
|
|
10111
10112
|
$registerRenameSupport(handle, selector, supportResolveLocation) {
|
|
10112
|
-
this._registrations.set(handle,
|
|
10113
|
+
this._registrations.set(handle, this._languageFeaturesService.renameProvider.register(selector, {
|
|
10113
10114
|
provideRenameEdits: (model, position, newName, token) => {
|
|
10114
10115
|
return this._proxy.$provideRenameEdits(handle, model.uri, position, newName, token).then(reviveWorkspaceEditDto);
|
|
10115
10116
|
},
|
|
@@ -10125,7 +10126,7 @@ define(['exports', 'monaco-editor/esm/vs/base/common/errors.js', 'monaco-editor/
|
|
|
10125
10126
|
this._registrations.set(eventHandle, emitter);
|
|
10126
10127
|
event = emitter.event;
|
|
10127
10128
|
}
|
|
10128
|
-
this._registrations.set(handle,
|
|
10129
|
+
this._registrations.set(handle, this._languageFeaturesService.documentSemanticTokensProvider.register(selector, /*#__PURE__*/ new MainThreadDocumentSemanticTokensProvider(this._proxy, handle, legend, event)));
|
|
10129
10130
|
}
|
|
10130
10131
|
$emitDocumentSemanticTokensEvent(eventHandle) {
|
|
10131
10132
|
const obj = this._registrations.get(eventHandle);
|
|
@@ -10134,7 +10135,7 @@ define(['exports', 'monaco-editor/esm/vs/base/common/errors.js', 'monaco-editor/
|
|
|
10134
10135
|
}
|
|
10135
10136
|
}
|
|
10136
10137
|
$registerDocumentRangeSemanticTokensProvider(handle, selector, legend) {
|
|
10137
|
-
this._registrations.set(handle,
|
|
10138
|
+
this._registrations.set(handle, this._languageFeaturesService.documentRangeSemanticTokensProvider.register(selector, /*#__PURE__*/ new MainThreadDocumentRangeSemanticTokensProvider(this._proxy, handle, legend)));
|
|
10138
10139
|
}
|
|
10139
10140
|
static _inflateSuggestDto(defaultRange, data) {
|
|
10140
10141
|
const label = data["a" ];
|
|
@@ -10188,7 +10189,7 @@ define(['exports', 'monaco-editor/esm/vs/base/common/errors.js', 'monaco-editor/
|
|
|
10188
10189
|
});
|
|
10189
10190
|
};
|
|
10190
10191
|
}
|
|
10191
|
-
this._registrations.set(handle,
|
|
10192
|
+
this._registrations.set(handle, this._languageFeaturesService.completionProvider.register(selector, provider));
|
|
10192
10193
|
}
|
|
10193
10194
|
$registerInlineCompletionsSupport(handle, selector) {
|
|
10194
10195
|
const provider = {
|
|
@@ -10202,10 +10203,10 @@ define(['exports', 'monaco-editor/esm/vs/base/common/errors.js', 'monaco-editor/
|
|
|
10202
10203
|
this._proxy.$freeInlineCompletionsList(handle, completions.pid);
|
|
10203
10204
|
}
|
|
10204
10205
|
};
|
|
10205
|
-
this._registrations.set(handle,
|
|
10206
|
+
this._registrations.set(handle, this._languageFeaturesService.inlineCompletionsProvider.register(selector, provider));
|
|
10206
10207
|
}
|
|
10207
10208
|
$registerSignatureHelpProvider(handle, selector, metadata) {
|
|
10208
|
-
this._registrations.set(handle,
|
|
10209
|
+
this._registrations.set(handle, this._languageFeaturesService.signatureHelpProvider.register(selector, {
|
|
10209
10210
|
signatureHelpTriggerCharacters: metadata.triggerCharacters,
|
|
10210
10211
|
signatureHelpRetriggerCharacters: metadata.retriggerCharacters,
|
|
10211
10212
|
provideSignatureHelp: async (model, position, token, context) => {
|
|
@@ -10265,7 +10266,7 @@ define(['exports', 'monaco-editor/esm/vs/base/common/errors.js', 'monaco-editor/
|
|
|
10265
10266
|
this._registrations.set(eventHandle, emitter);
|
|
10266
10267
|
provider.onDidChangeInlayHints = emitter.event;
|
|
10267
10268
|
}
|
|
10268
|
-
this._registrations.set(handle,
|
|
10269
|
+
this._registrations.set(handle, this._languageFeaturesService.inlayHintsProvider.register(selector, provider));
|
|
10269
10270
|
}
|
|
10270
10271
|
$emitInlayHintsEvent(eventHandle) {
|
|
10271
10272
|
const obj = this._registrations.get(eventHandle);
|
|
@@ -10302,11 +10303,11 @@ define(['exports', 'monaco-editor/esm/vs/base/common/errors.js', 'monaco-editor/
|
|
|
10302
10303
|
});
|
|
10303
10304
|
};
|
|
10304
10305
|
}
|
|
10305
|
-
this._registrations.set(handle,
|
|
10306
|
+
this._registrations.set(handle, this._languageFeaturesService.linkProvider.register(selector, provider));
|
|
10306
10307
|
}
|
|
10307
10308
|
$registerDocumentColorProvider(handle, selector) {
|
|
10308
10309
|
const proxy = this._proxy;
|
|
10309
|
-
this._registrations.set(handle,
|
|
10310
|
+
this._registrations.set(handle, this._languageFeaturesService.colorProvider.register(selector, {
|
|
10310
10311
|
provideDocumentColors: (model, token) => {
|
|
10311
10312
|
return proxy.$provideDocumentColors(handle, model.uri, token)
|
|
10312
10313
|
.then(documentColors => {
|
|
@@ -10344,7 +10345,7 @@ define(['exports', 'monaco-editor/esm/vs/base/common/errors.js', 'monaco-editor/
|
|
|
10344
10345
|
this._registrations.set(eventHandle, emitter);
|
|
10345
10346
|
provider.onDidChange = emitter.event;
|
|
10346
10347
|
}
|
|
10347
|
-
this._registrations.set(handle,
|
|
10348
|
+
this._registrations.set(handle, this._languageFeaturesService.foldingRangeProvider.register(selector, provider));
|
|
10348
10349
|
}
|
|
10349
10350
|
$emitFoldingRangeEvent(eventHandle, event) {
|
|
10350
10351
|
const obj = this._registrations.get(eventHandle);
|
|
@@ -10353,14 +10354,14 @@ define(['exports', 'monaco-editor/esm/vs/base/common/errors.js', 'monaco-editor/
|
|
|
10353
10354
|
}
|
|
10354
10355
|
}
|
|
10355
10356
|
$registerSelectionRangeProvider(handle, selector) {
|
|
10356
|
-
this._registrations.set(handle,
|
|
10357
|
+
this._registrations.set(handle, this._languageFeaturesService.selectionRangeProvider.register(selector, {
|
|
10357
10358
|
provideSelectionRanges: (model, positions, token) => {
|
|
10358
10359
|
return this._proxy.$provideSelectionRanges(handle, model.uri, positions, token);
|
|
10359
10360
|
}
|
|
10360
10361
|
}));
|
|
10361
10362
|
}
|
|
10362
10363
|
$registerCallHierarchyProvider(handle, selector) {
|
|
10363
|
-
this._registrations.set(handle,
|
|
10364
|
+
this._registrations.set(handle, CallHierarchyProviderRegistry.register(selector, {
|
|
10364
10365
|
prepareCallHierarchy: async (document, position, token) => {
|
|
10365
10366
|
const items = await this._proxy.$prepareCallHierarchy(handle, document.uri, position, token);
|
|
10366
10367
|
if (!items || items.length === 0) {
|
|
@@ -10444,11 +10445,11 @@ define(['exports', 'monaco-editor/esm/vs/base/common/errors.js', 'monaco-editor/
|
|
|
10444
10445
|
};
|
|
10445
10446
|
}
|
|
10446
10447
|
if (this._languageService.isRegisteredLanguageId(languageId)) {
|
|
10447
|
-
this._registrations.set(handle,
|
|
10448
|
+
this._registrations.set(handle, this._languageConfigurationService.register(languageId, configuration, 100));
|
|
10448
10449
|
}
|
|
10449
10450
|
}
|
|
10450
10451
|
$registerTypeHierarchyProvider(handle, selector) {
|
|
10451
|
-
this._registrations.set(handle,
|
|
10452
|
+
this._registrations.set(handle, TypeHierarchyProviderRegistry.register(selector, {
|
|
10452
10453
|
prepareTypeHierarchy: async (document, position, token) => {
|
|
10453
10454
|
const items = await this._proxy.$prepareTypeHierarchy(handle, document.uri, position, token);
|
|
10454
10455
|
if (!items) {
|
|
@@ -10480,7 +10481,7 @@ define(['exports', 'monaco-editor/esm/vs/base/common/errors.js', 'monaco-editor/
|
|
|
10480
10481
|
}));
|
|
10481
10482
|
}
|
|
10482
10483
|
$registerDocumentOnDropProvider(handle, selector) {
|
|
10483
|
-
this._registrations.set(handle,
|
|
10484
|
+
this._registrations.set(handle, this._languageFeaturesService.documentOnDropEditProvider.register(selector, {
|
|
10484
10485
|
provideDocumentOnDropEdits: async (model, position, dataTransfer, token) => {
|
|
10485
10486
|
const dataTransferDto = await DataTransferConverter.toDataTransferDTO(dataTransfer);
|
|
10486
10487
|
return this._proxy.$provideDocumentOnDropEdits(handle, model.uri, position, dataTransferDto, token);
|
package/dist/api.cjs
CHANGED
|
@@ -4681,7 +4681,7 @@ let ExtHostCommands = class ExtHostCommands {
|
|
|
4681
4681
|
this._argumentProcessors.push(processor);
|
|
4682
4682
|
}
|
|
4683
4683
|
registerApiCommand(apiCommand) {
|
|
4684
|
-
const registration =
|
|
4684
|
+
const registration = this.registerCommand(false, apiCommand.id, async (...apiArgs) => {
|
|
4685
4685
|
const internalArgs = apiCommand.args.map((arg, i) => {
|
|
4686
4686
|
if (!arg.validate(apiArgs[i])) {
|
|
4687
4687
|
throw new Error(`Invalid argument '${arg.name}' when running '${apiCommand.id}', received: ${apiArgs[i]}`);
|
|
@@ -4863,6 +4863,7 @@ class CommandsConverter {
|
|
|
4863
4863
|
this.delegatingCommandId = `_vscode_delegate_cmd_${Date.now().toString(36)}`;
|
|
4864
4864
|
this._cache = /*#__PURE__*/ new Map();
|
|
4865
4865
|
this._cachIdPool = 0;
|
|
4866
|
+
this._commands.registerCommand(true, this.delegatingCommandId, this._executeConvertedCommand, this);
|
|
4866
4867
|
}
|
|
4867
4868
|
toInternal(command, disposables) {
|
|
4868
4869
|
if (!command) {
|
|
@@ -9949,7 +9950,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
9949
9950
|
return data;
|
|
9950
9951
|
}
|
|
9951
9952
|
$registerDocumentSymbolProvider(handle, selector, displayName) {
|
|
9952
|
-
this._registrations.set(handle,
|
|
9953
|
+
this._registrations.set(handle, this._languageFeaturesService.documentSymbolProvider.register(selector, {
|
|
9953
9954
|
displayName,
|
|
9954
9955
|
provideDocumentSymbols: (model, token) => {
|
|
9955
9956
|
return this._proxy.$provideDocumentSymbols(handle, model.uri, token);
|
|
@@ -9977,7 +9978,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
9977
9978
|
this._registrations.set(eventHandle, emitter);
|
|
9978
9979
|
provider.onDidChange = emitter.event;
|
|
9979
9980
|
}
|
|
9980
|
-
this._registrations.set(handle,
|
|
9981
|
+
this._registrations.set(handle, this._languageFeaturesService.codeLensProvider.register(selector, provider));
|
|
9981
9982
|
}
|
|
9982
9983
|
$emitCodeLensEvent(eventHandle, event) {
|
|
9983
9984
|
const obj = this._registrations.get(eventHandle);
|
|
@@ -9986,42 +9987,42 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
9986
9987
|
}
|
|
9987
9988
|
}
|
|
9988
9989
|
$registerDefinitionSupport(handle, selector) {
|
|
9989
|
-
this._registrations.set(handle,
|
|
9990
|
+
this._registrations.set(handle, this._languageFeaturesService.definitionProvider.register(selector, {
|
|
9990
9991
|
provideDefinition: (model, position, token) => {
|
|
9991
9992
|
return this._proxy.$provideDefinition(handle, model.uri, position, token).then(MainThreadLanguageFeatures_1._reviveLocationLinkDto);
|
|
9992
9993
|
}
|
|
9993
9994
|
}));
|
|
9994
9995
|
}
|
|
9995
9996
|
$registerDeclarationSupport(handle, selector) {
|
|
9996
|
-
this._registrations.set(handle,
|
|
9997
|
+
this._registrations.set(handle, this._languageFeaturesService.declarationProvider.register(selector, {
|
|
9997
9998
|
provideDeclaration: (model, position, token) => {
|
|
9998
9999
|
return this._proxy.$provideDeclaration(handle, model.uri, position, token).then(MainThreadLanguageFeatures_1._reviveLocationLinkDto);
|
|
9999
10000
|
}
|
|
10000
10001
|
}));
|
|
10001
10002
|
}
|
|
10002
10003
|
$registerImplementationSupport(handle, selector) {
|
|
10003
|
-
this._registrations.set(handle,
|
|
10004
|
+
this._registrations.set(handle, this._languageFeaturesService.implementationProvider.register(selector, {
|
|
10004
10005
|
provideImplementation: (model, position, token) => {
|
|
10005
10006
|
return this._proxy.$provideImplementation(handle, model.uri, position, token).then(MainThreadLanguageFeatures_1._reviveLocationLinkDto);
|
|
10006
10007
|
}
|
|
10007
10008
|
}));
|
|
10008
10009
|
}
|
|
10009
10010
|
$registerTypeDefinitionSupport(handle, selector) {
|
|
10010
|
-
this._registrations.set(handle,
|
|
10011
|
+
this._registrations.set(handle, this._languageFeaturesService.typeDefinitionProvider.register(selector, {
|
|
10011
10012
|
provideTypeDefinition: (model, position, token) => {
|
|
10012
10013
|
return this._proxy.$provideTypeDefinition(handle, model.uri, position, token).then(MainThreadLanguageFeatures_1._reviveLocationLinkDto);
|
|
10013
10014
|
}
|
|
10014
10015
|
}));
|
|
10015
10016
|
}
|
|
10016
10017
|
$registerHoverProvider(handle, selector) {
|
|
10017
|
-
this._registrations.set(handle,
|
|
10018
|
+
this._registrations.set(handle, this._languageFeaturesService.hoverProvider.register(selector, {
|
|
10018
10019
|
provideHover: (model, position, token) => {
|
|
10019
10020
|
return this._proxy.$provideHover(handle, model.uri, position, token);
|
|
10020
10021
|
}
|
|
10021
10022
|
}));
|
|
10022
10023
|
}
|
|
10023
10024
|
$registerEvaluatableExpressionProvider(handle, selector) {
|
|
10024
|
-
this._registrations.set(handle,
|
|
10025
|
+
this._registrations.set(handle, this._languageFeaturesService.evaluatableExpressionProvider.register(selector, {
|
|
10025
10026
|
provideEvaluatableExpression: (model, position, token) => {
|
|
10026
10027
|
return this._proxy.$provideEvaluatableExpression(handle, model.uri, position, token);
|
|
10027
10028
|
}
|
|
@@ -10038,7 +10039,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10038
10039
|
this._registrations.set(eventHandle, emitter);
|
|
10039
10040
|
provider.onDidChangeInlineValues = emitter.event;
|
|
10040
10041
|
}
|
|
10041
|
-
this._registrations.set(handle,
|
|
10042
|
+
this._registrations.set(handle, this._languageFeaturesService.inlineValuesProvider.register(selector, provider));
|
|
10042
10043
|
}
|
|
10043
10044
|
$emitInlineValuesEvent(eventHandle, event) {
|
|
10044
10045
|
const obj = this._registrations.get(eventHandle);
|
|
@@ -10047,14 +10048,14 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10047
10048
|
}
|
|
10048
10049
|
}
|
|
10049
10050
|
$registerDocumentHighlightProvider(handle, selector) {
|
|
10050
|
-
this._registrations.set(handle,
|
|
10051
|
+
this._registrations.set(handle, this._languageFeaturesService.documentHighlightProvider.register(selector, {
|
|
10051
10052
|
provideDocumentHighlights: (model, position, token) => {
|
|
10052
10053
|
return this._proxy.$provideDocumentHighlights(handle, model.uri, position, token);
|
|
10053
10054
|
}
|
|
10054
10055
|
}));
|
|
10055
10056
|
}
|
|
10056
10057
|
$registerLinkedEditingRangeProvider(handle, selector) {
|
|
10057
|
-
this._registrations.set(handle,
|
|
10058
|
+
this._registrations.set(handle, this._languageFeaturesService.linkedEditingRangeProvider.register(selector, {
|
|
10058
10059
|
provideLinkedEditingRanges: async (model, position, token) => {
|
|
10059
10060
|
const res = await this._proxy.$provideLinkedEditingRanges(handle, model.uri, position, token);
|
|
10060
10061
|
if (res) {
|
|
@@ -10068,7 +10069,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10068
10069
|
}));
|
|
10069
10070
|
}
|
|
10070
10071
|
$registerReferenceSupport(handle, selector) {
|
|
10071
|
-
this._registrations.set(handle,
|
|
10072
|
+
this._registrations.set(handle, this._languageFeaturesService.referenceProvider.register(selector, {
|
|
10072
10073
|
provideReferences: (model, position, context, token) => {
|
|
10073
10074
|
return this._proxy.$provideReferences(handle, model.uri, position, context, token).then(MainThreadLanguageFeatures_1._reviveLocationDto);
|
|
10074
10075
|
}
|
|
@@ -10101,10 +10102,10 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10101
10102
|
return codeAction;
|
|
10102
10103
|
};
|
|
10103
10104
|
}
|
|
10104
|
-
this._registrations.set(handle,
|
|
10105
|
+
this._registrations.set(handle, this._languageFeaturesService.codeActionProvider.register(selector, provider));
|
|
10105
10106
|
}
|
|
10106
10107
|
$registerDocumentFormattingSupport(handle, selector, extensionId, displayName) {
|
|
10107
|
-
this._registrations.set(handle,
|
|
10108
|
+
this._registrations.set(handle, this._languageFeaturesService.documentFormattingEditProvider.register(selector, {
|
|
10108
10109
|
extensionId,
|
|
10109
10110
|
displayName,
|
|
10110
10111
|
provideDocumentFormattingEdits: (model, options, token) => {
|
|
@@ -10113,7 +10114,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10113
10114
|
}));
|
|
10114
10115
|
}
|
|
10115
10116
|
$registerRangeFormattingSupport(handle, selector, extensionId, displayName) {
|
|
10116
|
-
this._registrations.set(handle,
|
|
10117
|
+
this._registrations.set(handle, this._languageFeaturesService.documentRangeFormattingEditProvider.register(selector, {
|
|
10117
10118
|
extensionId,
|
|
10118
10119
|
displayName,
|
|
10119
10120
|
provideDocumentRangeFormattingEdits: (model, range, options, token) => {
|
|
@@ -10122,7 +10123,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10122
10123
|
}));
|
|
10123
10124
|
}
|
|
10124
10125
|
$registerOnTypeFormattingSupport(handle, selector, autoFormatTriggerCharacters, extensionId) {
|
|
10125
|
-
this._registrations.set(handle,
|
|
10126
|
+
this._registrations.set(handle, this._languageFeaturesService.onTypeFormattingEditProvider.register(selector, {
|
|
10126
10127
|
extensionId,
|
|
10127
10128
|
autoFormatTriggerCharacters,
|
|
10128
10129
|
provideOnTypeFormattingEdits: (model, position, ch, options, token) => {
|
|
@@ -10148,10 +10149,10 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10148
10149
|
return resolvedItem && MainThreadLanguageFeatures_1._reviveWorkspaceSymbolDto(resolvedItem);
|
|
10149
10150
|
};
|
|
10150
10151
|
}
|
|
10151
|
-
this._registrations.set(handle,
|
|
10152
|
+
this._registrations.set(handle, WorkspaceSymbolProviderRegistry.register(provider));
|
|
10152
10153
|
}
|
|
10153
10154
|
$registerRenameSupport(handle, selector, supportResolveLocation) {
|
|
10154
|
-
this._registrations.set(handle,
|
|
10155
|
+
this._registrations.set(handle, this._languageFeaturesService.renameProvider.register(selector, {
|
|
10155
10156
|
provideRenameEdits: (model, position, newName, token) => {
|
|
10156
10157
|
return this._proxy.$provideRenameEdits(handle, model.uri, position, newName, token).then(reviveWorkspaceEditDto);
|
|
10157
10158
|
},
|
|
@@ -10167,7 +10168,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10167
10168
|
this._registrations.set(eventHandle, emitter);
|
|
10168
10169
|
event = emitter.event;
|
|
10169
10170
|
}
|
|
10170
|
-
this._registrations.set(handle,
|
|
10171
|
+
this._registrations.set(handle, this._languageFeaturesService.documentSemanticTokensProvider.register(selector, /*#__PURE__*/ new MainThreadDocumentSemanticTokensProvider(this._proxy, handle, legend, event)));
|
|
10171
10172
|
}
|
|
10172
10173
|
$emitDocumentSemanticTokensEvent(eventHandle) {
|
|
10173
10174
|
const obj = this._registrations.get(eventHandle);
|
|
@@ -10176,7 +10177,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10176
10177
|
}
|
|
10177
10178
|
}
|
|
10178
10179
|
$registerDocumentRangeSemanticTokensProvider(handle, selector, legend) {
|
|
10179
|
-
this._registrations.set(handle,
|
|
10180
|
+
this._registrations.set(handle, this._languageFeaturesService.documentRangeSemanticTokensProvider.register(selector, /*#__PURE__*/ new MainThreadDocumentRangeSemanticTokensProvider(this._proxy, handle, legend)));
|
|
10180
10181
|
}
|
|
10181
10182
|
static _inflateSuggestDto(defaultRange, data) {
|
|
10182
10183
|
const label = data["a" ];
|
|
@@ -10230,7 +10231,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10230
10231
|
});
|
|
10231
10232
|
};
|
|
10232
10233
|
}
|
|
10233
|
-
this._registrations.set(handle,
|
|
10234
|
+
this._registrations.set(handle, this._languageFeaturesService.completionProvider.register(selector, provider));
|
|
10234
10235
|
}
|
|
10235
10236
|
$registerInlineCompletionsSupport(handle, selector) {
|
|
10236
10237
|
const provider = {
|
|
@@ -10244,10 +10245,10 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10244
10245
|
this._proxy.$freeInlineCompletionsList(handle, completions.pid);
|
|
10245
10246
|
}
|
|
10246
10247
|
};
|
|
10247
|
-
this._registrations.set(handle,
|
|
10248
|
+
this._registrations.set(handle, this._languageFeaturesService.inlineCompletionsProvider.register(selector, provider));
|
|
10248
10249
|
}
|
|
10249
10250
|
$registerSignatureHelpProvider(handle, selector, metadata) {
|
|
10250
|
-
this._registrations.set(handle,
|
|
10251
|
+
this._registrations.set(handle, this._languageFeaturesService.signatureHelpProvider.register(selector, {
|
|
10251
10252
|
signatureHelpTriggerCharacters: metadata.triggerCharacters,
|
|
10252
10253
|
signatureHelpRetriggerCharacters: metadata.retriggerCharacters,
|
|
10253
10254
|
provideSignatureHelp: async (model, position, token, context) => {
|
|
@@ -10307,7 +10308,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10307
10308
|
this._registrations.set(eventHandle, emitter);
|
|
10308
10309
|
provider.onDidChangeInlayHints = emitter.event;
|
|
10309
10310
|
}
|
|
10310
|
-
this._registrations.set(handle,
|
|
10311
|
+
this._registrations.set(handle, this._languageFeaturesService.inlayHintsProvider.register(selector, provider));
|
|
10311
10312
|
}
|
|
10312
10313
|
$emitInlayHintsEvent(eventHandle) {
|
|
10313
10314
|
const obj = this._registrations.get(eventHandle);
|
|
@@ -10344,11 +10345,11 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10344
10345
|
});
|
|
10345
10346
|
};
|
|
10346
10347
|
}
|
|
10347
|
-
this._registrations.set(handle,
|
|
10348
|
+
this._registrations.set(handle, this._languageFeaturesService.linkProvider.register(selector, provider));
|
|
10348
10349
|
}
|
|
10349
10350
|
$registerDocumentColorProvider(handle, selector) {
|
|
10350
10351
|
const proxy = this._proxy;
|
|
10351
|
-
this._registrations.set(handle,
|
|
10352
|
+
this._registrations.set(handle, this._languageFeaturesService.colorProvider.register(selector, {
|
|
10352
10353
|
provideDocumentColors: (model, token) => {
|
|
10353
10354
|
return proxy.$provideDocumentColors(handle, model.uri, token)
|
|
10354
10355
|
.then(documentColors => {
|
|
@@ -10386,7 +10387,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10386
10387
|
this._registrations.set(eventHandle, emitter);
|
|
10387
10388
|
provider.onDidChange = emitter.event;
|
|
10388
10389
|
}
|
|
10389
|
-
this._registrations.set(handle,
|
|
10390
|
+
this._registrations.set(handle, this._languageFeaturesService.foldingRangeProvider.register(selector, provider));
|
|
10390
10391
|
}
|
|
10391
10392
|
$emitFoldingRangeEvent(eventHandle, event) {
|
|
10392
10393
|
const obj = this._registrations.get(eventHandle);
|
|
@@ -10395,14 +10396,14 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10395
10396
|
}
|
|
10396
10397
|
}
|
|
10397
10398
|
$registerSelectionRangeProvider(handle, selector) {
|
|
10398
|
-
this._registrations.set(handle,
|
|
10399
|
+
this._registrations.set(handle, this._languageFeaturesService.selectionRangeProvider.register(selector, {
|
|
10399
10400
|
provideSelectionRanges: (model, positions, token) => {
|
|
10400
10401
|
return this._proxy.$provideSelectionRanges(handle, model.uri, positions, token);
|
|
10401
10402
|
}
|
|
10402
10403
|
}));
|
|
10403
10404
|
}
|
|
10404
10405
|
$registerCallHierarchyProvider(handle, selector) {
|
|
10405
|
-
this._registrations.set(handle,
|
|
10406
|
+
this._registrations.set(handle, CallHierarchyProviderRegistry.register(selector, {
|
|
10406
10407
|
prepareCallHierarchy: async (document, position, token) => {
|
|
10407
10408
|
const items = await this._proxy.$prepareCallHierarchy(handle, document.uri, position, token);
|
|
10408
10409
|
if (!items || items.length === 0) {
|
|
@@ -10486,11 +10487,11 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10486
10487
|
};
|
|
10487
10488
|
}
|
|
10488
10489
|
if (this._languageService.isRegisteredLanguageId(languageId)) {
|
|
10489
|
-
this._registrations.set(handle,
|
|
10490
|
+
this._registrations.set(handle, this._languageConfigurationService.register(languageId, configuration, 100));
|
|
10490
10491
|
}
|
|
10491
10492
|
}
|
|
10492
10493
|
$registerTypeHierarchyProvider(handle, selector) {
|
|
10493
|
-
this._registrations.set(handle,
|
|
10494
|
+
this._registrations.set(handle, TypeHierarchyProviderRegistry.register(selector, {
|
|
10494
10495
|
prepareTypeHierarchy: async (document, position, token) => {
|
|
10495
10496
|
const items = await this._proxy.$prepareTypeHierarchy(handle, document.uri, position, token);
|
|
10496
10497
|
if (!items) {
|
|
@@ -10522,7 +10523,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10522
10523
|
}));
|
|
10523
10524
|
}
|
|
10524
10525
|
$registerDocumentOnDropProvider(handle, selector) {
|
|
10525
|
-
this._registrations.set(handle,
|
|
10526
|
+
this._registrations.set(handle, this._languageFeaturesService.documentOnDropEditProvider.register(selector, {
|
|
10526
10527
|
provideDocumentOnDropEdits: async (model, position, dataTransfer, token) => {
|
|
10527
10528
|
const dataTransferDto = await DataTransferConverter.toDataTransferDTO(dataTransfer);
|
|
10528
10529
|
return this._proxy.$provideDocumentOnDropEdits(handle, model.uri, position, dataTransferDto, token);
|
package/dist/api.js
CHANGED
|
@@ -4654,7 +4654,7 @@ let ExtHostCommands = class ExtHostCommands {
|
|
|
4654
4654
|
this._argumentProcessors.push(processor);
|
|
4655
4655
|
}
|
|
4656
4656
|
registerApiCommand(apiCommand) {
|
|
4657
|
-
const registration =
|
|
4657
|
+
const registration = this.registerCommand(false, apiCommand.id, async (...apiArgs) => {
|
|
4658
4658
|
const internalArgs = apiCommand.args.map((arg, i) => {
|
|
4659
4659
|
if (!arg.validate(apiArgs[i])) {
|
|
4660
4660
|
throw new Error(`Invalid argument '${arg.name}' when running '${apiCommand.id}', received: ${apiArgs[i]}`);
|
|
@@ -4836,6 +4836,7 @@ class CommandsConverter {
|
|
|
4836
4836
|
this.delegatingCommandId = `_vscode_delegate_cmd_${Date.now().toString(36)}`;
|
|
4837
4837
|
this._cache = /*#__PURE__*/ new Map();
|
|
4838
4838
|
this._cachIdPool = 0;
|
|
4839
|
+
this._commands.registerCommand(true, this.delegatingCommandId, this._executeConvertedCommand, this);
|
|
4839
4840
|
}
|
|
4840
4841
|
toInternal(command, disposables) {
|
|
4841
4842
|
if (!command) {
|
|
@@ -9922,7 +9923,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
9922
9923
|
return data;
|
|
9923
9924
|
}
|
|
9924
9925
|
$registerDocumentSymbolProvider(handle, selector, displayName) {
|
|
9925
|
-
this._registrations.set(handle,
|
|
9926
|
+
this._registrations.set(handle, this._languageFeaturesService.documentSymbolProvider.register(selector, {
|
|
9926
9927
|
displayName,
|
|
9927
9928
|
provideDocumentSymbols: (model, token) => {
|
|
9928
9929
|
return this._proxy.$provideDocumentSymbols(handle, model.uri, token);
|
|
@@ -9950,7 +9951,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
9950
9951
|
this._registrations.set(eventHandle, emitter);
|
|
9951
9952
|
provider.onDidChange = emitter.event;
|
|
9952
9953
|
}
|
|
9953
|
-
this._registrations.set(handle,
|
|
9954
|
+
this._registrations.set(handle, this._languageFeaturesService.codeLensProvider.register(selector, provider));
|
|
9954
9955
|
}
|
|
9955
9956
|
$emitCodeLensEvent(eventHandle, event) {
|
|
9956
9957
|
const obj = this._registrations.get(eventHandle);
|
|
@@ -9959,42 +9960,42 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
9959
9960
|
}
|
|
9960
9961
|
}
|
|
9961
9962
|
$registerDefinitionSupport(handle, selector) {
|
|
9962
|
-
this._registrations.set(handle,
|
|
9963
|
+
this._registrations.set(handle, this._languageFeaturesService.definitionProvider.register(selector, {
|
|
9963
9964
|
provideDefinition: (model, position, token) => {
|
|
9964
9965
|
return this._proxy.$provideDefinition(handle, model.uri, position, token).then(MainThreadLanguageFeatures_1._reviveLocationLinkDto);
|
|
9965
9966
|
}
|
|
9966
9967
|
}));
|
|
9967
9968
|
}
|
|
9968
9969
|
$registerDeclarationSupport(handle, selector) {
|
|
9969
|
-
this._registrations.set(handle,
|
|
9970
|
+
this._registrations.set(handle, this._languageFeaturesService.declarationProvider.register(selector, {
|
|
9970
9971
|
provideDeclaration: (model, position, token) => {
|
|
9971
9972
|
return this._proxy.$provideDeclaration(handle, model.uri, position, token).then(MainThreadLanguageFeatures_1._reviveLocationLinkDto);
|
|
9972
9973
|
}
|
|
9973
9974
|
}));
|
|
9974
9975
|
}
|
|
9975
9976
|
$registerImplementationSupport(handle, selector) {
|
|
9976
|
-
this._registrations.set(handle,
|
|
9977
|
+
this._registrations.set(handle, this._languageFeaturesService.implementationProvider.register(selector, {
|
|
9977
9978
|
provideImplementation: (model, position, token) => {
|
|
9978
9979
|
return this._proxy.$provideImplementation(handle, model.uri, position, token).then(MainThreadLanguageFeatures_1._reviveLocationLinkDto);
|
|
9979
9980
|
}
|
|
9980
9981
|
}));
|
|
9981
9982
|
}
|
|
9982
9983
|
$registerTypeDefinitionSupport(handle, selector) {
|
|
9983
|
-
this._registrations.set(handle,
|
|
9984
|
+
this._registrations.set(handle, this._languageFeaturesService.typeDefinitionProvider.register(selector, {
|
|
9984
9985
|
provideTypeDefinition: (model, position, token) => {
|
|
9985
9986
|
return this._proxy.$provideTypeDefinition(handle, model.uri, position, token).then(MainThreadLanguageFeatures_1._reviveLocationLinkDto);
|
|
9986
9987
|
}
|
|
9987
9988
|
}));
|
|
9988
9989
|
}
|
|
9989
9990
|
$registerHoverProvider(handle, selector) {
|
|
9990
|
-
this._registrations.set(handle,
|
|
9991
|
+
this._registrations.set(handle, this._languageFeaturesService.hoverProvider.register(selector, {
|
|
9991
9992
|
provideHover: (model, position, token) => {
|
|
9992
9993
|
return this._proxy.$provideHover(handle, model.uri, position, token);
|
|
9993
9994
|
}
|
|
9994
9995
|
}));
|
|
9995
9996
|
}
|
|
9996
9997
|
$registerEvaluatableExpressionProvider(handle, selector) {
|
|
9997
|
-
this._registrations.set(handle,
|
|
9998
|
+
this._registrations.set(handle, this._languageFeaturesService.evaluatableExpressionProvider.register(selector, {
|
|
9998
9999
|
provideEvaluatableExpression: (model, position, token) => {
|
|
9999
10000
|
return this._proxy.$provideEvaluatableExpression(handle, model.uri, position, token);
|
|
10000
10001
|
}
|
|
@@ -10011,7 +10012,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10011
10012
|
this._registrations.set(eventHandle, emitter);
|
|
10012
10013
|
provider.onDidChangeInlineValues = emitter.event;
|
|
10013
10014
|
}
|
|
10014
|
-
this._registrations.set(handle,
|
|
10015
|
+
this._registrations.set(handle, this._languageFeaturesService.inlineValuesProvider.register(selector, provider));
|
|
10015
10016
|
}
|
|
10016
10017
|
$emitInlineValuesEvent(eventHandle, event) {
|
|
10017
10018
|
const obj = this._registrations.get(eventHandle);
|
|
@@ -10020,14 +10021,14 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10020
10021
|
}
|
|
10021
10022
|
}
|
|
10022
10023
|
$registerDocumentHighlightProvider(handle, selector) {
|
|
10023
|
-
this._registrations.set(handle,
|
|
10024
|
+
this._registrations.set(handle, this._languageFeaturesService.documentHighlightProvider.register(selector, {
|
|
10024
10025
|
provideDocumentHighlights: (model, position, token) => {
|
|
10025
10026
|
return this._proxy.$provideDocumentHighlights(handle, model.uri, position, token);
|
|
10026
10027
|
}
|
|
10027
10028
|
}));
|
|
10028
10029
|
}
|
|
10029
10030
|
$registerLinkedEditingRangeProvider(handle, selector) {
|
|
10030
|
-
this._registrations.set(handle,
|
|
10031
|
+
this._registrations.set(handle, this._languageFeaturesService.linkedEditingRangeProvider.register(selector, {
|
|
10031
10032
|
provideLinkedEditingRanges: async (model, position, token) => {
|
|
10032
10033
|
const res = await this._proxy.$provideLinkedEditingRanges(handle, model.uri, position, token);
|
|
10033
10034
|
if (res) {
|
|
@@ -10041,7 +10042,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10041
10042
|
}));
|
|
10042
10043
|
}
|
|
10043
10044
|
$registerReferenceSupport(handle, selector) {
|
|
10044
|
-
this._registrations.set(handle,
|
|
10045
|
+
this._registrations.set(handle, this._languageFeaturesService.referenceProvider.register(selector, {
|
|
10045
10046
|
provideReferences: (model, position, context, token) => {
|
|
10046
10047
|
return this._proxy.$provideReferences(handle, model.uri, position, context, token).then(MainThreadLanguageFeatures_1._reviveLocationDto);
|
|
10047
10048
|
}
|
|
@@ -10074,10 +10075,10 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10074
10075
|
return codeAction;
|
|
10075
10076
|
};
|
|
10076
10077
|
}
|
|
10077
|
-
this._registrations.set(handle,
|
|
10078
|
+
this._registrations.set(handle, this._languageFeaturesService.codeActionProvider.register(selector, provider));
|
|
10078
10079
|
}
|
|
10079
10080
|
$registerDocumentFormattingSupport(handle, selector, extensionId, displayName) {
|
|
10080
|
-
this._registrations.set(handle,
|
|
10081
|
+
this._registrations.set(handle, this._languageFeaturesService.documentFormattingEditProvider.register(selector, {
|
|
10081
10082
|
extensionId,
|
|
10082
10083
|
displayName,
|
|
10083
10084
|
provideDocumentFormattingEdits: (model, options, token) => {
|
|
@@ -10086,7 +10087,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10086
10087
|
}));
|
|
10087
10088
|
}
|
|
10088
10089
|
$registerRangeFormattingSupport(handle, selector, extensionId, displayName) {
|
|
10089
|
-
this._registrations.set(handle,
|
|
10090
|
+
this._registrations.set(handle, this._languageFeaturesService.documentRangeFormattingEditProvider.register(selector, {
|
|
10090
10091
|
extensionId,
|
|
10091
10092
|
displayName,
|
|
10092
10093
|
provideDocumentRangeFormattingEdits: (model, range, options, token) => {
|
|
@@ -10095,7 +10096,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10095
10096
|
}));
|
|
10096
10097
|
}
|
|
10097
10098
|
$registerOnTypeFormattingSupport(handle, selector, autoFormatTriggerCharacters, extensionId) {
|
|
10098
|
-
this._registrations.set(handle,
|
|
10099
|
+
this._registrations.set(handle, this._languageFeaturesService.onTypeFormattingEditProvider.register(selector, {
|
|
10099
10100
|
extensionId,
|
|
10100
10101
|
autoFormatTriggerCharacters,
|
|
10101
10102
|
provideOnTypeFormattingEdits: (model, position, ch, options, token) => {
|
|
@@ -10121,10 +10122,10 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10121
10122
|
return resolvedItem && MainThreadLanguageFeatures_1._reviveWorkspaceSymbolDto(resolvedItem);
|
|
10122
10123
|
};
|
|
10123
10124
|
}
|
|
10124
|
-
this._registrations.set(handle,
|
|
10125
|
+
this._registrations.set(handle, WorkspaceSymbolProviderRegistry.register(provider));
|
|
10125
10126
|
}
|
|
10126
10127
|
$registerRenameSupport(handle, selector, supportResolveLocation) {
|
|
10127
|
-
this._registrations.set(handle,
|
|
10128
|
+
this._registrations.set(handle, this._languageFeaturesService.renameProvider.register(selector, {
|
|
10128
10129
|
provideRenameEdits: (model, position, newName, token) => {
|
|
10129
10130
|
return this._proxy.$provideRenameEdits(handle, model.uri, position, newName, token).then(reviveWorkspaceEditDto);
|
|
10130
10131
|
},
|
|
@@ -10140,7 +10141,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10140
10141
|
this._registrations.set(eventHandle, emitter);
|
|
10141
10142
|
event = emitter.event;
|
|
10142
10143
|
}
|
|
10143
|
-
this._registrations.set(handle,
|
|
10144
|
+
this._registrations.set(handle, this._languageFeaturesService.documentSemanticTokensProvider.register(selector, /*#__PURE__*/ new MainThreadDocumentSemanticTokensProvider(this._proxy, handle, legend, event)));
|
|
10144
10145
|
}
|
|
10145
10146
|
$emitDocumentSemanticTokensEvent(eventHandle) {
|
|
10146
10147
|
const obj = this._registrations.get(eventHandle);
|
|
@@ -10149,7 +10150,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10149
10150
|
}
|
|
10150
10151
|
}
|
|
10151
10152
|
$registerDocumentRangeSemanticTokensProvider(handle, selector, legend) {
|
|
10152
|
-
this._registrations.set(handle,
|
|
10153
|
+
this._registrations.set(handle, this._languageFeaturesService.documentRangeSemanticTokensProvider.register(selector, /*#__PURE__*/ new MainThreadDocumentRangeSemanticTokensProvider(this._proxy, handle, legend)));
|
|
10153
10154
|
}
|
|
10154
10155
|
static _inflateSuggestDto(defaultRange, data) {
|
|
10155
10156
|
const label = data["a" ];
|
|
@@ -10203,7 +10204,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10203
10204
|
});
|
|
10204
10205
|
};
|
|
10205
10206
|
}
|
|
10206
|
-
this._registrations.set(handle,
|
|
10207
|
+
this._registrations.set(handle, this._languageFeaturesService.completionProvider.register(selector, provider));
|
|
10207
10208
|
}
|
|
10208
10209
|
$registerInlineCompletionsSupport(handle, selector) {
|
|
10209
10210
|
const provider = {
|
|
@@ -10217,10 +10218,10 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10217
10218
|
this._proxy.$freeInlineCompletionsList(handle, completions.pid);
|
|
10218
10219
|
}
|
|
10219
10220
|
};
|
|
10220
|
-
this._registrations.set(handle,
|
|
10221
|
+
this._registrations.set(handle, this._languageFeaturesService.inlineCompletionsProvider.register(selector, provider));
|
|
10221
10222
|
}
|
|
10222
10223
|
$registerSignatureHelpProvider(handle, selector, metadata) {
|
|
10223
|
-
this._registrations.set(handle,
|
|
10224
|
+
this._registrations.set(handle, this._languageFeaturesService.signatureHelpProvider.register(selector, {
|
|
10224
10225
|
signatureHelpTriggerCharacters: metadata.triggerCharacters,
|
|
10225
10226
|
signatureHelpRetriggerCharacters: metadata.retriggerCharacters,
|
|
10226
10227
|
provideSignatureHelp: async (model, position, token, context) => {
|
|
@@ -10280,7 +10281,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10280
10281
|
this._registrations.set(eventHandle, emitter);
|
|
10281
10282
|
provider.onDidChangeInlayHints = emitter.event;
|
|
10282
10283
|
}
|
|
10283
|
-
this._registrations.set(handle,
|
|
10284
|
+
this._registrations.set(handle, this._languageFeaturesService.inlayHintsProvider.register(selector, provider));
|
|
10284
10285
|
}
|
|
10285
10286
|
$emitInlayHintsEvent(eventHandle) {
|
|
10286
10287
|
const obj = this._registrations.get(eventHandle);
|
|
@@ -10317,11 +10318,11 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10317
10318
|
});
|
|
10318
10319
|
};
|
|
10319
10320
|
}
|
|
10320
|
-
this._registrations.set(handle,
|
|
10321
|
+
this._registrations.set(handle, this._languageFeaturesService.linkProvider.register(selector, provider));
|
|
10321
10322
|
}
|
|
10322
10323
|
$registerDocumentColorProvider(handle, selector) {
|
|
10323
10324
|
const proxy = this._proxy;
|
|
10324
|
-
this._registrations.set(handle,
|
|
10325
|
+
this._registrations.set(handle, this._languageFeaturesService.colorProvider.register(selector, {
|
|
10325
10326
|
provideDocumentColors: (model, token) => {
|
|
10326
10327
|
return proxy.$provideDocumentColors(handle, model.uri, token)
|
|
10327
10328
|
.then(documentColors => {
|
|
@@ -10359,7 +10360,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10359
10360
|
this._registrations.set(eventHandle, emitter);
|
|
10360
10361
|
provider.onDidChange = emitter.event;
|
|
10361
10362
|
}
|
|
10362
|
-
this._registrations.set(handle,
|
|
10363
|
+
this._registrations.set(handle, this._languageFeaturesService.foldingRangeProvider.register(selector, provider));
|
|
10363
10364
|
}
|
|
10364
10365
|
$emitFoldingRangeEvent(eventHandle, event) {
|
|
10365
10366
|
const obj = this._registrations.get(eventHandle);
|
|
@@ -10368,14 +10369,14 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10368
10369
|
}
|
|
10369
10370
|
}
|
|
10370
10371
|
$registerSelectionRangeProvider(handle, selector) {
|
|
10371
|
-
this._registrations.set(handle,
|
|
10372
|
+
this._registrations.set(handle, this._languageFeaturesService.selectionRangeProvider.register(selector, {
|
|
10372
10373
|
provideSelectionRanges: (model, positions, token) => {
|
|
10373
10374
|
return this._proxy.$provideSelectionRanges(handle, model.uri, positions, token);
|
|
10374
10375
|
}
|
|
10375
10376
|
}));
|
|
10376
10377
|
}
|
|
10377
10378
|
$registerCallHierarchyProvider(handle, selector) {
|
|
10378
|
-
this._registrations.set(handle,
|
|
10379
|
+
this._registrations.set(handle, CallHierarchyProviderRegistry.register(selector, {
|
|
10379
10380
|
prepareCallHierarchy: async (document, position, token) => {
|
|
10380
10381
|
const items = await this._proxy.$prepareCallHierarchy(handle, document.uri, position, token);
|
|
10381
10382
|
if (!items || items.length === 0) {
|
|
@@ -10459,11 +10460,11 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10459
10460
|
};
|
|
10460
10461
|
}
|
|
10461
10462
|
if (this._languageService.isRegisteredLanguageId(languageId)) {
|
|
10462
|
-
this._registrations.set(handle,
|
|
10463
|
+
this._registrations.set(handle, this._languageConfigurationService.register(languageId, configuration, 100));
|
|
10463
10464
|
}
|
|
10464
10465
|
}
|
|
10465
10466
|
$registerTypeHierarchyProvider(handle, selector) {
|
|
10466
|
-
this._registrations.set(handle,
|
|
10467
|
+
this._registrations.set(handle, TypeHierarchyProviderRegistry.register(selector, {
|
|
10467
10468
|
prepareTypeHierarchy: async (document, position, token) => {
|
|
10468
10469
|
const items = await this._proxy.$prepareTypeHierarchy(handle, document.uri, position, token);
|
|
10469
10470
|
if (!items) {
|
|
@@ -10495,7 +10496,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
10495
10496
|
}));
|
|
10496
10497
|
}
|
|
10497
10498
|
$registerDocumentOnDropProvider(handle, selector) {
|
|
10498
|
-
this._registrations.set(handle,
|
|
10499
|
+
this._registrations.set(handle, this._languageFeaturesService.documentOnDropEditProvider.register(selector, {
|
|
10499
10500
|
provideDocumentOnDropEdits: async (model, position, dataTransfer, token) => {
|
|
10500
10501
|
const dataTransferDto = await DataTransferConverter.toDataTransferDTO(dataTransfer);
|
|
10501
10502
|
return this._proxy.$provideDocumentOnDropEdits(handle, model.uri, position, dataTransferDto, token);
|