@codingame/monaco-vscode-api 1.67.8-dev.0 → 1.67.10
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/README.md +27 -3
- package/dist/api.js +578 -1820
- package/dist/async-9ffe4d42.js +46 -0
- package/dist/messages.d.ts +7 -0
- package/dist/messages.js +4305 -0
- package/dist/missing-services-8a03a564.js +812 -0
- package/dist/modelEditor.d.ts +158 -0
- package/dist/modelEditor.js +717 -0
- package/dist/services-ac6b4b50.js +747 -0
- package/dist/services.d.ts +5360 -9322
- package/dist/services.js +17 -2
- package/package.json +34 -19
- package/dist/services-f1f30499.js +0 -300
package/dist/api.js
CHANGED
|
@@ -1,37 +1,47 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { i as isStringArray, E as Emitter, u as unsupported$1 } from './missing-services-8a03a564.js';
|
|
2
|
+
import { _ as __classPrivateFieldSet, a as __classPrivateFieldGet, b as __decorate, c as coalesceInPlace, m as markAsFileSystemProviderError, F as FileSystemProviderErrorCode, S as SIDE_GROUP, A as ACTIVE_GROUP, d as __param, C as CancellationTokenSource$1, I as IProgressService, r as readonly, e as ITextFileService, f as IFileService, g as IWorkbenchEnvironmentService, h as IUriIdentityService, i as IWorkingCopyFileService, j as IPathService, k as disposed, l as IEditorService, n as IEditorGroupsService, o as IPaneCompositePartService, p as IProductService, q as ILanguageStatusService, s as IHostService, t as Services, u as FileType$1, v as FilePermission$1 } from './services-ac6b4b50.js';
|
|
3
|
+
import { illegalArgument, onUnexpectedError, canceled, transformErrorForSerialization, isCancellationError, onUnexpectedExternalError, CancellationError as CancellationError$1 } from 'monaco-editor/esm/vs/base/common/errors.js';
|
|
3
4
|
import { uriToFsPath, URI } from 'monaco-editor/esm/vs/base/common/uri.js';
|
|
4
|
-
import { equals
|
|
5
|
+
import { equals, coalesce, asArray, isNonEmptyArray, groupBy, isFalsyOrEmpty } from 'monaco-editor/esm/vs/base/common/arrays.js';
|
|
5
6
|
import { MarkdownString as MarkdownString$3, parseHrefAndDimensions, isMarkdownString } from 'monaco-editor/esm/vs/base/common/htmlContent.js';
|
|
6
7
|
import { generateUuid } from 'monaco-editor/esm/vs/base/common/uuid.js';
|
|
7
8
|
import { compare, equalsIgnoreCase, nextCharLength, regExpLeadsToEndlessLoop, splitLines, isFalsyOrWhitespace, regExpFlags } from 'monaco-editor/esm/vs/base/common/strings.js';
|
|
8
9
|
import { Mimes } from 'monaco-editor/esm/vs/base/common/mime.js';
|
|
9
|
-
import { isArray,
|
|
10
|
-
import { ResourceMap
|
|
11
|
-
import * as monaco from 'monaco-editor/esm/vs/editor/editor.api.js';
|
|
10
|
+
import { isArray, isString, isNumber, validateConstraint, assertIsDefined, withNullAsUndefined, isObject } from 'monaco-editor/esm/vs/base/common/types.js';
|
|
11
|
+
import { ResourceMap } from 'monaco-editor/esm/vs/base/common/map.js';
|
|
12
12
|
import { marked as marked$1 } from 'monaco-editor/esm/vs/base/common/marked/marked.js';
|
|
13
|
+
import * as monaco from 'monaco-editor/esm/vs/editor/editor.api.js';
|
|
13
14
|
import { MarkerSeverity, IMarkerService } from 'monaco-editor/esm/vs/platform/markers/common/markers.js';
|
|
14
15
|
import { parse, revive } from 'monaco-editor/esm/vs/base/common/marshalling.js';
|
|
15
|
-
import { cloneAndChange, deepFreeze, equals as equals$
|
|
16
|
+
import { cloneAndChange, deepFreeze, equals as equals$1, mixin } from 'monaco-editor/esm/vs/base/common/objects.js';
|
|
16
17
|
import { VSBuffer } from 'monaco-editor/esm/vs/base/common/buffer.js';
|
|
18
|
+
import { createDecorator } from 'monaco-editor/esm/vs/platform/instantiation/common/instantiation.js';
|
|
17
19
|
import { toErrorMessage } from 'monaco-editor/esm/vs/base/common/errorMessage.js';
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import { ExtensionIdentifier } from 'monaco-editor/esm/vs/platform/extensions/common/extensions.js';
|
|
20
|
+
import { ILogService, LogService } from 'monaco-editor/esm/vs/platform/log/common/log.js';
|
|
21
|
+
import { Disposable as Disposable$2, toDisposable, dispose, combinedDisposable, DisposableStore } from 'monaco-editor/esm/vs/base/common/lifecycle.js';
|
|
21
22
|
import { Event, DebounceEmitter } from 'monaco-editor/esm/vs/base/common/event.js';
|
|
22
|
-
import {
|
|
23
|
+
import { CommandsRegistry, ICommandService } from 'monaco-editor/esm/vs/platform/commands/common/commands.js';
|
|
23
24
|
import { Schemas } from 'monaco-editor/esm/vs/base/common/network.js';
|
|
24
|
-
import { ExtUri as ExtUri$1, extUri as extUri$1
|
|
25
|
+
import { ExtUri as ExtUri$1, extUri as extUri$1 } from 'monaco-editor/esm/vs/base/common/resources.js';
|
|
26
|
+
import { localize } from 'monaco-editor/esm/vs/nls.js';
|
|
25
27
|
import { RunOnceScheduler, createCancelablePromise, disposableTimeout } from 'monaco-editor/esm/vs/base/common/async.js';
|
|
26
28
|
import { CancellationToken } from 'monaco-editor/esm/vs/base/common/cancellation.js';
|
|
27
29
|
import { MirrorTextModel } from 'monaco-editor/esm/vs/editor/common/model/mirrorTextModel.js';
|
|
28
30
|
import { ok } from 'monaco-editor/esm/vs/base/common/assert.js';
|
|
29
31
|
import { getWordAtText, ensureValidWordDefinition } from 'monaco-editor/esm/vs/editor/common/core/wordHelper.js';
|
|
30
|
-
import {
|
|
32
|
+
import { a as asPromise, r as raceCancellationError } from './async-9ffe4d42.js';
|
|
33
|
+
import { ThemeIcon as ThemeIcon$2 } from 'monaco-editor/esm/vs/platform/theme/common/themeService.js';
|
|
31
34
|
import Severity from 'monaco-editor/esm/vs/base/common/severity.js';
|
|
32
|
-
import {
|
|
35
|
+
import { IQuickInputService } from 'monaco-editor/esm/vs/platform/quickinput/common/quickInput.js';
|
|
36
|
+
import { IDialogService } from 'monaco-editor/esm/vs/platform/dialogs/common/dialogs.js';
|
|
37
|
+
import { INotificationService } from 'monaco-editor/esm/vs/platform/notification/common/notification.js';
|
|
38
|
+
import { Action } from 'monaco-editor/esm/vs/base/common/actions.js';
|
|
33
39
|
import { Progress } from 'monaco-editor/esm/vs/platform/progress/common/progress.js';
|
|
34
40
|
import { EditOperation } from 'monaco-editor/esm/vs/editor/common/core/editOperation.js';
|
|
41
|
+
import { ITextModelService } from 'monaco-editor/esm/vs/editor/common/services/resolverService.js';
|
|
42
|
+
import { ILanguageService } from 'monaco-editor/esm/vs/editor/common/languages/language.js';
|
|
43
|
+
import { IModelService } from 'monaco-editor/esm/vs/editor/common/services/model.js';
|
|
44
|
+
import { IEditorWorkerService } from 'monaco-editor/esm/vs/editor/common/services/editorWorker.js';
|
|
35
45
|
import { IdGenerator } from 'monaco-editor/esm/vs/base/common/idGenerator.js';
|
|
36
46
|
import { Lazy } from 'monaco-editor/esm/vs/base/common/lazy.js';
|
|
37
47
|
import { Iterable } from 'monaco-editor/esm/vs/base/common/iterator.js';
|
|
@@ -44,107 +54,31 @@ import { SnippetController2 } from 'monaco-editor/esm/vs/editor/contrib/snippet/
|
|
|
44
54
|
import { EditorState } from 'monaco-editor/esm/vs/editor/contrib/editorState/browser/editorState.js';
|
|
45
55
|
import { TextEditorCursorStyle as TextEditorCursorStyle$2 } from 'monaco-editor/esm/vs/editor/common/config/editorOptions.js';
|
|
46
56
|
import { ResourceEdit, ResourceFileEdit, ResourceTextEdit, IBulkEditService } from 'monaco-editor/esm/vs/editor/browser/services/bulkEditService.js';
|
|
47
|
-
import { Registry } from 'monaco-editor/esm/vs/platform/registry/common/platform.js';
|
|
48
|
-
import { IInstantiationService, createDecorator } from 'monaco-editor/esm/vs/platform/instantiation/common/instantiation.js';
|
|
49
|
-
import { trackFocus, Dimension } from 'monaco-editor/esm/vs/base/browser/dom.js';
|
|
50
|
-
import { isCodeEditor, getCodeEditor, isDiffEditor } from 'monaco-editor/esm/vs/editor/browser/editorBrowser.js';
|
|
51
|
-
import { IContextKeyService } from 'monaco-editor/esm/vs/platform/contextkey/common/contextkey.js';
|
|
52
|
-
import { CodeEditorWidget } from 'monaco-editor/esm/vs/editor/browser/widget/codeEditorWidget.js';
|
|
53
|
-
import { registerSingleton } from 'monaco-editor/esm/vs/platform/instantiation/common/extensions.js';
|
|
54
|
-
import { LanguageFeatureRegistry } from 'monaco-editor/esm/vs/editor/common/languageFeatureRegistry.js';
|
|
55
|
-
import { encodeSemanticTokensDto } from 'monaco-editor/esm/vs/editor/common/services/semanticTokensDto.js';
|
|
56
|
-
import { StopWatch } from 'monaco-editor/esm/vs/base/common/stopwatch.js';
|
|
57
|
-
import { LanguageConfigurationRegistry, ILanguageConfigurationService } from 'monaco-editor/esm/vs/editor/common/languages/languageConfigurationRegistry.js';
|
|
58
|
-
import { StandaloneServices } from 'monaco-editor/esm/vs/editor/standalone/browser/standaloneServices.js';
|
|
59
|
-
import { INotificationService } from 'monaco-editor/esm/vs/platform/notification/common/notification.js';
|
|
60
|
-
import { IDialogService } from 'monaco-editor/esm/vs/platform/dialogs/common/dialogs.js';
|
|
61
|
-
import { ITextModelService } from 'monaco-editor/esm/vs/editor/common/services/resolverService.js';
|
|
62
|
-
import { IModelService } from 'monaco-editor/esm/vs/editor/common/services/model.js';
|
|
63
|
-
import { ILanguageService } from 'monaco-editor/esm/vs/editor/common/languages/language.js';
|
|
64
|
-
import { IEditorWorkerService } from 'monaco-editor/esm/vs/editor/common/services/editorWorker.js';
|
|
65
|
-
import { IQuickInputService } from 'monaco-editor/esm/vs/platform/quickinput/common/quickInput.js';
|
|
66
57
|
import { ICodeEditorService } from 'monaco-editor/esm/vs/editor/browser/services/codeEditorService.js';
|
|
67
58
|
import { IClipboardService } from 'monaco-editor/esm/vs/platform/clipboard/common/clipboardService.js';
|
|
59
|
+
import { isCodeEditor, isDiffEditor } from 'monaco-editor/esm/vs/editor/browser/editorBrowser.js';
|
|
68
60
|
import { ITelemetryService } from 'monaco-editor/esm/vs/platform/telemetry/common/telemetry.js';
|
|
61
|
+
import { IConfigurationService } from 'monaco-editor/esm/vs/platform/configuration/common/configuration.js';
|
|
62
|
+
import { IEnvironmentService } from 'monaco-editor/esm/vs/platform/environment/common/environment.js';
|
|
69
63
|
import { IOpenerService, matchesScheme } from 'monaco-editor/esm/vs/platform/opener/common/opener.js';
|
|
64
|
+
import { encodeSemanticTokensDto } from 'monaco-editor/esm/vs/editor/common/services/semanticTokensDto.js';
|
|
65
|
+
import { StopWatch } from 'monaco-editor/esm/vs/base/common/stopwatch.js';
|
|
66
|
+
import { LanguageFeatureRegistry } from 'monaco-editor/esm/vs/editor/common/languageFeatureRegistry.js';
|
|
67
|
+
import { LanguageConfigurationRegistry, ILanguageConfigurationService } from 'monaco-editor/esm/vs/editor/common/languages/languageConfigurationRegistry.js';
|
|
70
68
|
import { ILanguageFeaturesService } from 'monaco-editor/esm/vs/editor/common/services/languageFeatures.js';
|
|
71
|
-
import {
|
|
72
|
-
import {
|
|
69
|
+
import { ExtensionIdentifier } from 'monaco-editor/esm/vs/platform/extensions/common/extensions.js';
|
|
70
|
+
import { StandaloneServices } from 'monaco-editor/esm/vs/editor/standalone/browser/standaloneServices.js';
|
|
73
71
|
import { score } from 'monaco-editor/esm/vs/editor/common/languageSelector.js';
|
|
74
72
|
import { IndentAction as IndentAction$1 } from 'monaco-editor/esm/vs/editor/common/languages/languageConfiguration.js';
|
|
75
|
-
import 'monaco-editor/esm/vs/
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
|
|
85
|
-
return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
|
|
86
|
-
}
|
|
87
|
-
function coalesceInPlace(array) {
|
|
88
|
-
let to = 0;
|
|
89
|
-
for (let i = 0; i < array.length; i++) {
|
|
90
|
-
if (!!array[i]) {
|
|
91
|
-
array[to] = array[i];
|
|
92
|
-
to += 1;
|
|
93
|
-
}
|
|
94
|
-
}
|
|
95
|
-
array.length = to;
|
|
96
|
-
}
|
|
97
|
-
function insert(array, element) {
|
|
98
|
-
array.push(element);
|
|
99
|
-
return () => remove(array, element);
|
|
100
|
-
}
|
|
101
|
-
function remove(array, element) {
|
|
102
|
-
const index = array.indexOf(element);
|
|
103
|
-
if (index > -1) {
|
|
104
|
-
array.splice(index, 1);
|
|
105
|
-
return element;
|
|
106
|
-
}
|
|
107
|
-
return undefined;
|
|
108
|
-
}
|
|
109
|
-
const CancellationTokenSource$1 = monaco.CancellationTokenSource;
|
|
110
|
-
function isString(str) {
|
|
111
|
-
return (typeof str === 'string');
|
|
112
|
-
}
|
|
113
|
-
function isStringArray(value) {
|
|
114
|
-
return Array.isArray(value) && value.every(elem => isString(elem));
|
|
115
|
-
}
|
|
116
|
-
function isObject(obj) {
|
|
117
|
-
return typeof obj === 'object'
|
|
118
|
-
&& obj !== null
|
|
119
|
-
&& !Array.isArray(obj)
|
|
120
|
-
&& !(obj instanceof RegExp)
|
|
121
|
-
&& !(obj instanceof Date);
|
|
122
|
-
}
|
|
123
|
-
const hasOwnProperty = Object.prototype.hasOwnProperty;
|
|
124
|
-
function isEmptyObject(obj) {
|
|
125
|
-
if (!isObject(obj)) {
|
|
126
|
-
return false;
|
|
127
|
-
}
|
|
128
|
-
for (let key in obj) {
|
|
129
|
-
if (hasOwnProperty.call(obj, key)) {
|
|
130
|
-
return false;
|
|
131
|
-
}
|
|
132
|
-
}
|
|
133
|
-
return true;
|
|
134
|
-
}
|
|
135
|
-
function indexOfPath(path, candidate, ignoreCase) {
|
|
136
|
-
if (candidate.length > path.length) {
|
|
137
|
-
return -1;
|
|
138
|
-
}
|
|
139
|
-
if (path === candidate) {
|
|
140
|
-
return 0;
|
|
141
|
-
}
|
|
142
|
-
if (ignoreCase) {
|
|
143
|
-
path = path.toLowerCase();
|
|
144
|
-
candidate = candidate.toLowerCase();
|
|
145
|
-
}
|
|
146
|
-
return path.indexOf(candidate);
|
|
147
|
-
}
|
|
73
|
+
import 'monaco-editor/esm/vs/base/browser/ui/progressbar/progressbar.js';
|
|
74
|
+
import 'monaco-editor/esm/vs/base/common/color.js';
|
|
75
|
+
import 'monaco-editor/esm/vs/base/browser/dom.js';
|
|
76
|
+
import 'monaco-editor/esm/vs/base/parts/quickinput/browser/quickInput.js';
|
|
77
|
+
import 'monaco-editor/esm/vs/platform/instantiation/common/extensions.js';
|
|
78
|
+
import 'monaco-editor/esm/vs/platform/label/common/label.js';
|
|
79
|
+
import 'monaco-editor/esm/vs/base/browser/event.js';
|
|
80
|
+
import 'monaco-editor/esm/vs/platform/workspace/common/workspace.js';
|
|
81
|
+
import 'monaco-editor/esm/vs/base/common/linkedList.js';
|
|
148
82
|
function originalFSPath(uri) {
|
|
149
83
|
return uriToFsPath(uri, true);
|
|
150
84
|
}
|
|
@@ -346,6 +280,13 @@ function normalizeMimeType(mimeType, strict) {
|
|
|
346
280
|
}
|
|
347
281
|
var _Disposable_callOnDispose, _MarkdownString_delegate, _a$1, _NotebookCellOutputItem_encoder;
|
|
348
282
|
var Disposable_1, Position_1, Range_1, Selection_1, TextEdit_1, SnippetString_1, Location_1, SymbolInformation_1, DocumentSymbol_1, CodeActionKind_1, MarkdownString_1, TaskGroup_1, Task_1, FileSystemError_1, TestMessage_1;
|
|
283
|
+
function es5ClassCompat(target) {
|
|
284
|
+
function _() { return Reflect.construct(target, arguments, this.constructor); }
|
|
285
|
+
Object.defineProperty(_, 'name', Object.getOwnPropertyDescriptor(target, 'name'));
|
|
286
|
+
Object.setPrototypeOf(_, target);
|
|
287
|
+
Object.setPrototypeOf(_.prototype, target.prototype);
|
|
288
|
+
return _;
|
|
289
|
+
}
|
|
349
290
|
let Disposable$1 = Disposable_1 = class Disposable {
|
|
350
291
|
constructor(callOnDispose) {
|
|
351
292
|
_Disposable_callOnDispose.set(this, void 0);
|
|
@@ -374,7 +315,9 @@ let Disposable$1 = Disposable_1 = class Disposable {
|
|
|
374
315
|
}
|
|
375
316
|
};
|
|
376
317
|
_Disposable_callOnDispose = new WeakMap();
|
|
377
|
-
Disposable$1 = Disposable_1 =
|
|
318
|
+
Disposable$1 = Disposable_1 = __decorate([
|
|
319
|
+
es5ClassCompat
|
|
320
|
+
], Disposable$1);
|
|
378
321
|
let Position$3 = Position_1 = class Position {
|
|
379
322
|
constructor(line, character) {
|
|
380
323
|
if (line < 0) {
|
|
@@ -536,7 +479,9 @@ let Position$3 = Position_1 = class Position {
|
|
|
536
479
|
return { line: this.line, character: this.character };
|
|
537
480
|
}
|
|
538
481
|
};
|
|
539
|
-
Position$3 = Position_1 =
|
|
482
|
+
Position$3 = Position_1 = __decorate([
|
|
483
|
+
es5ClassCompat
|
|
484
|
+
], Position$3);
|
|
540
485
|
let Range$3 = Range_1 = class Range {
|
|
541
486
|
constructor(startLineOrStart, startColumnOrEnd, endLine, endColumn) {
|
|
542
487
|
let start;
|
|
@@ -662,7 +607,9 @@ let Range$3 = Range_1 = class Range {
|
|
|
662
607
|
return [this.start, this.end];
|
|
663
608
|
}
|
|
664
609
|
};
|
|
665
|
-
Range$3 = Range_1 =
|
|
610
|
+
Range$3 = Range_1 = __decorate([
|
|
611
|
+
es5ClassCompat
|
|
612
|
+
], Range$3);
|
|
666
613
|
let Selection$3 = Selection_1 = class Selection extends Range$3 {
|
|
667
614
|
constructor(anchorLineOrAnchor, anchorColumnOrActive, activeLine, activeColumn) {
|
|
668
615
|
let anchor;
|
|
@@ -712,7 +659,9 @@ let Selection$3 = Selection_1 = class Selection extends Range$3 {
|
|
|
712
659
|
};
|
|
713
660
|
}
|
|
714
661
|
};
|
|
715
|
-
Selection$3 = Selection_1 =
|
|
662
|
+
Selection$3 = Selection_1 = __decorate([
|
|
663
|
+
es5ClassCompat
|
|
664
|
+
], Selection$3);
|
|
716
665
|
var EndOfLine$2;
|
|
717
666
|
(function(EndOfLine) {
|
|
718
667
|
EndOfLine[EndOfLine["LF"] = 1] = "LF";
|
|
@@ -790,7 +739,9 @@ let TextEdit$2 = TextEdit_1 = class TextEdit {
|
|
|
790
739
|
};
|
|
791
740
|
}
|
|
792
741
|
};
|
|
793
|
-
TextEdit$2 = TextEdit_1 =
|
|
742
|
+
TextEdit$2 = TextEdit_1 = __decorate([
|
|
743
|
+
es5ClassCompat
|
|
744
|
+
], TextEdit$2);
|
|
794
745
|
let WorkspaceEdit$2 = class WorkspaceEdit {
|
|
795
746
|
constructor() {
|
|
796
747
|
this._edits = [];
|
|
@@ -897,7 +848,9 @@ let WorkspaceEdit$2 = class WorkspaceEdit {
|
|
|
897
848
|
return this.entries();
|
|
898
849
|
}
|
|
899
850
|
};
|
|
900
|
-
WorkspaceEdit$2 =
|
|
851
|
+
WorkspaceEdit$2 = __decorate([
|
|
852
|
+
es5ClassCompat
|
|
853
|
+
], WorkspaceEdit$2);
|
|
901
854
|
let SnippetString$1 = SnippetString_1 = class SnippetString {
|
|
902
855
|
constructor(value) {
|
|
903
856
|
this._tabstop = 1;
|
|
@@ -972,7 +925,9 @@ let SnippetString$1 = SnippetString_1 = class SnippetString {
|
|
|
972
925
|
return this;
|
|
973
926
|
}
|
|
974
927
|
};
|
|
975
|
-
SnippetString$1 = SnippetString_1 =
|
|
928
|
+
SnippetString$1 = SnippetString_1 = __decorate([
|
|
929
|
+
es5ClassCompat
|
|
930
|
+
], SnippetString$1);
|
|
976
931
|
var DiagnosticTag$2;
|
|
977
932
|
(function(DiagnosticTag) {
|
|
978
933
|
DiagnosticTag[DiagnosticTag["Unnecessary"] = 1] = "Unnecessary";
|
|
@@ -1016,7 +971,9 @@ let Location$1 = Location_1 = class Location {
|
|
|
1016
971
|
};
|
|
1017
972
|
}
|
|
1018
973
|
};
|
|
1019
|
-
Location$1 = Location_1 =
|
|
974
|
+
Location$1 = Location_1 = __decorate([
|
|
975
|
+
es5ClassCompat
|
|
976
|
+
], Location$1);
|
|
1020
977
|
let DiagnosticRelatedInformation$2 = class DiagnosticRelatedInformation {
|
|
1021
978
|
constructor(location, message) {
|
|
1022
979
|
this.location = location;
|
|
@@ -1043,7 +1000,9 @@ let DiagnosticRelatedInformation$2 = class DiagnosticRelatedInformation {
|
|
|
1043
1000
|
&& a.location.uri.toString() === b.location.uri.toString();
|
|
1044
1001
|
}
|
|
1045
1002
|
};
|
|
1046
|
-
DiagnosticRelatedInformation$2 =
|
|
1003
|
+
DiagnosticRelatedInformation$2 = __decorate([
|
|
1004
|
+
es5ClassCompat
|
|
1005
|
+
], DiagnosticRelatedInformation$2);
|
|
1047
1006
|
let Diagnostic$2 = class Diagnostic {
|
|
1048
1007
|
constructor(range, message, severity = DiagnosticSeverity$2.Error) {
|
|
1049
1008
|
if (!Range$3.isRange(range)) {
|
|
@@ -1078,11 +1037,13 @@ let Diagnostic$2 = class Diagnostic {
|
|
|
1078
1037
|
&& a.severity === b.severity
|
|
1079
1038
|
&& a.source === b.source
|
|
1080
1039
|
&& a.range.isEqual(b.range)
|
|
1081
|
-
&& equals
|
|
1082
|
-
&& equals
|
|
1040
|
+
&& equals(a.tags, b.tags)
|
|
1041
|
+
&& equals(a.relatedInformation, b.relatedInformation, DiagnosticRelatedInformation$2.isEqual);
|
|
1083
1042
|
}
|
|
1084
1043
|
};
|
|
1085
|
-
Diagnostic$2 =
|
|
1044
|
+
Diagnostic$2 = __decorate([
|
|
1045
|
+
es5ClassCompat
|
|
1046
|
+
], Diagnostic$2);
|
|
1086
1047
|
let Hover$2 = class Hover {
|
|
1087
1048
|
constructor(contents, range) {
|
|
1088
1049
|
if (!contents) {
|
|
@@ -1097,7 +1058,9 @@ let Hover$2 = class Hover {
|
|
|
1097
1058
|
this.range = range;
|
|
1098
1059
|
}
|
|
1099
1060
|
};
|
|
1100
|
-
Hover$2 =
|
|
1061
|
+
Hover$2 = __decorate([
|
|
1062
|
+
es5ClassCompat
|
|
1063
|
+
], Hover$2);
|
|
1101
1064
|
var DocumentHighlightKind$1;
|
|
1102
1065
|
(function(DocumentHighlightKind) {
|
|
1103
1066
|
DocumentHighlightKind[DocumentHighlightKind["Text"] = 0] = "Text";
|
|
@@ -1116,7 +1079,9 @@ let DocumentHighlight$2 = class DocumentHighlight {
|
|
|
1116
1079
|
};
|
|
1117
1080
|
}
|
|
1118
1081
|
};
|
|
1119
|
-
DocumentHighlight$2 =
|
|
1082
|
+
DocumentHighlight$2 = __decorate([
|
|
1083
|
+
es5ClassCompat
|
|
1084
|
+
], DocumentHighlight$2);
|
|
1120
1085
|
var SymbolKind$2;
|
|
1121
1086
|
(function(SymbolKind) {
|
|
1122
1087
|
SymbolKind[SymbolKind["File"] = 0] = "File";
|
|
@@ -1180,7 +1145,9 @@ let SymbolInformation$1 = SymbolInformation_1 = class SymbolInformation {
|
|
|
1180
1145
|
};
|
|
1181
1146
|
}
|
|
1182
1147
|
};
|
|
1183
|
-
SymbolInformation$1 = SymbolInformation_1 =
|
|
1148
|
+
SymbolInformation$1 = SymbolInformation_1 = __decorate([
|
|
1149
|
+
es5ClassCompat
|
|
1150
|
+
], SymbolInformation$1);
|
|
1184
1151
|
let DocumentSymbol$2 = DocumentSymbol_1 = class DocumentSymbol {
|
|
1185
1152
|
constructor(name, detail, kind, range, selectionRange) {
|
|
1186
1153
|
this.name = name;
|
|
@@ -1203,7 +1170,9 @@ let DocumentSymbol$2 = DocumentSymbol_1 = class DocumentSymbol {
|
|
|
1203
1170
|
}
|
|
1204
1171
|
}
|
|
1205
1172
|
};
|
|
1206
|
-
DocumentSymbol$2 = DocumentSymbol_1 =
|
|
1173
|
+
DocumentSymbol$2 = DocumentSymbol_1 = __decorate([
|
|
1174
|
+
es5ClassCompat
|
|
1175
|
+
], DocumentSymbol$2);
|
|
1207
1176
|
var CodeActionTriggerKind$2;
|
|
1208
1177
|
(function(CodeActionTriggerKind) {
|
|
1209
1178
|
CodeActionTriggerKind[CodeActionTriggerKind["Invoke"] = 1] = "Invoke";
|
|
@@ -1215,7 +1184,9 @@ let CodeAction$1 = class CodeAction {
|
|
|
1215
1184
|
this.kind = kind;
|
|
1216
1185
|
}
|
|
1217
1186
|
};
|
|
1218
|
-
CodeAction$1 =
|
|
1187
|
+
CodeAction$1 = __decorate([
|
|
1188
|
+
es5ClassCompat
|
|
1189
|
+
], CodeAction$1);
|
|
1219
1190
|
let CodeActionKind$1 = CodeActionKind_1 = class CodeActionKind {
|
|
1220
1191
|
constructor(value) {
|
|
1221
1192
|
this.value = value;
|
|
@@ -1233,7 +1204,9 @@ let CodeActionKind$1 = CodeActionKind_1 = class CodeActionKind {
|
|
|
1233
1204
|
}
|
|
1234
1205
|
};
|
|
1235
1206
|
CodeActionKind$1.sep = '.';
|
|
1236
|
-
CodeActionKind$1 = CodeActionKind_1 =
|
|
1207
|
+
CodeActionKind$1 = CodeActionKind_1 = __decorate([
|
|
1208
|
+
es5ClassCompat
|
|
1209
|
+
], CodeActionKind$1);
|
|
1237
1210
|
CodeActionKind$1.Empty = new CodeActionKind$1('');
|
|
1238
1211
|
CodeActionKind$1.QuickFix = CodeActionKind$1.Empty.append('quickfix');
|
|
1239
1212
|
CodeActionKind$1.Refactor = CodeActionKind$1.Empty.append('refactor');
|
|
@@ -1252,7 +1225,9 @@ let SelectionRange$2 = class SelectionRange {
|
|
|
1252
1225
|
}
|
|
1253
1226
|
}
|
|
1254
1227
|
};
|
|
1255
|
-
SelectionRange$2 =
|
|
1228
|
+
SelectionRange$2 = __decorate([
|
|
1229
|
+
es5ClassCompat
|
|
1230
|
+
], SelectionRange$2);
|
|
1256
1231
|
class CallHierarchyItem$2 {
|
|
1257
1232
|
constructor(kind, name, detail, uri, range, selectionRange) {
|
|
1258
1233
|
this.kind = kind;
|
|
@@ -1290,7 +1265,9 @@ let CodeLens$1 = class CodeLens {
|
|
|
1290
1265
|
return !!this.command;
|
|
1291
1266
|
}
|
|
1292
1267
|
};
|
|
1293
|
-
CodeLens$1 =
|
|
1268
|
+
CodeLens$1 = __decorate([
|
|
1269
|
+
es5ClassCompat
|
|
1270
|
+
], CodeLens$1);
|
|
1294
1271
|
let MarkdownString$2 = MarkdownString_1 = class MarkdownString {
|
|
1295
1272
|
constructor(value, supportThemeIcons = false) {
|
|
1296
1273
|
_MarkdownString_delegate.set(this, void 0);
|
|
@@ -1346,14 +1323,18 @@ let MarkdownString$2 = MarkdownString_1 = class MarkdownString {
|
|
|
1346
1323
|
}
|
|
1347
1324
|
};
|
|
1348
1325
|
_MarkdownString_delegate = new WeakMap();
|
|
1349
|
-
MarkdownString$2 = MarkdownString_1 =
|
|
1326
|
+
MarkdownString$2 = MarkdownString_1 = __decorate([
|
|
1327
|
+
es5ClassCompat
|
|
1328
|
+
], MarkdownString$2);
|
|
1350
1329
|
let ParameterInformation$2 = class ParameterInformation {
|
|
1351
1330
|
constructor(label, documentation) {
|
|
1352
1331
|
this.label = label;
|
|
1353
1332
|
this.documentation = documentation;
|
|
1354
1333
|
}
|
|
1355
1334
|
};
|
|
1356
|
-
ParameterInformation$2 =
|
|
1335
|
+
ParameterInformation$2 = __decorate([
|
|
1336
|
+
es5ClassCompat
|
|
1337
|
+
], ParameterInformation$2);
|
|
1357
1338
|
let SignatureInformation$2 = class SignatureInformation {
|
|
1358
1339
|
constructor(label, documentation) {
|
|
1359
1340
|
this.label = label;
|
|
@@ -1361,7 +1342,9 @@ let SignatureInformation$2 = class SignatureInformation {
|
|
|
1361
1342
|
this.parameters = [];
|
|
1362
1343
|
}
|
|
1363
1344
|
};
|
|
1364
|
-
SignatureInformation$2 =
|
|
1345
|
+
SignatureInformation$2 = __decorate([
|
|
1346
|
+
es5ClassCompat
|
|
1347
|
+
], SignatureInformation$2);
|
|
1365
1348
|
let SignatureHelp$2 = class SignatureHelp {
|
|
1366
1349
|
constructor() {
|
|
1367
1350
|
this.activeSignature = 0;
|
|
@@ -1369,7 +1352,9 @@ let SignatureHelp$2 = class SignatureHelp {
|
|
|
1369
1352
|
this.signatures = [];
|
|
1370
1353
|
}
|
|
1371
1354
|
};
|
|
1372
|
-
SignatureHelp$2 =
|
|
1355
|
+
SignatureHelp$2 = __decorate([
|
|
1356
|
+
es5ClassCompat
|
|
1357
|
+
], SignatureHelp$2);
|
|
1373
1358
|
var SignatureHelpTriggerKind$1;
|
|
1374
1359
|
(function(SignatureHelpTriggerKind) {
|
|
1375
1360
|
SignatureHelpTriggerKind[SignatureHelpTriggerKind["Invoke"] = 1] = "Invoke";
|
|
@@ -1386,7 +1371,9 @@ let InlayHintLabelPart$1 = class InlayHintLabelPart {
|
|
|
1386
1371
|
this.value = value;
|
|
1387
1372
|
}
|
|
1388
1373
|
};
|
|
1389
|
-
InlayHintLabelPart$1 =
|
|
1374
|
+
InlayHintLabelPart$1 = __decorate([
|
|
1375
|
+
es5ClassCompat
|
|
1376
|
+
], InlayHintLabelPart$1);
|
|
1390
1377
|
let InlayHint$1 = class InlayHint {
|
|
1391
1378
|
constructor(position, label, kind) {
|
|
1392
1379
|
this.position = position;
|
|
@@ -1394,7 +1381,9 @@ let InlayHint$1 = class InlayHint {
|
|
|
1394
1381
|
this.kind = kind;
|
|
1395
1382
|
}
|
|
1396
1383
|
};
|
|
1397
|
-
InlayHint$1 =
|
|
1384
|
+
InlayHint$1 = __decorate([
|
|
1385
|
+
es5ClassCompat
|
|
1386
|
+
], InlayHint$1);
|
|
1398
1387
|
var CompletionTriggerKind$2;
|
|
1399
1388
|
(function(CompletionTriggerKind) {
|
|
1400
1389
|
CompletionTriggerKind[CompletionTriggerKind["Invoke"] = 0] = "Invoke";
|
|
@@ -1454,14 +1443,18 @@ let CompletionItem$1 = class CompletionItem {
|
|
|
1454
1443
|
};
|
|
1455
1444
|
}
|
|
1456
1445
|
};
|
|
1457
|
-
CompletionItem$1 =
|
|
1446
|
+
CompletionItem$1 = __decorate([
|
|
1447
|
+
es5ClassCompat
|
|
1448
|
+
], CompletionItem$1);
|
|
1458
1449
|
let CompletionList$1 = class CompletionList {
|
|
1459
1450
|
constructor(items = [], isIncomplete = false) {
|
|
1460
1451
|
this.items = items;
|
|
1461
1452
|
this.isIncomplete = isIncomplete;
|
|
1462
1453
|
}
|
|
1463
1454
|
};
|
|
1464
|
-
CompletionList$1 =
|
|
1455
|
+
CompletionList$1 = __decorate([
|
|
1456
|
+
es5ClassCompat
|
|
1457
|
+
], CompletionList$1);
|
|
1465
1458
|
var ViewColumn$2;
|
|
1466
1459
|
(function(ViewColumn) {
|
|
1467
1460
|
ViewColumn[ViewColumn["Active"] = -1] = "Active";
|
|
@@ -1541,7 +1534,9 @@ let DocumentLink$2 = class DocumentLink {
|
|
|
1541
1534
|
this.target = target;
|
|
1542
1535
|
}
|
|
1543
1536
|
};
|
|
1544
|
-
DocumentLink$2 =
|
|
1537
|
+
DocumentLink$2 = __decorate([
|
|
1538
|
+
es5ClassCompat
|
|
1539
|
+
], DocumentLink$2);
|
|
1545
1540
|
let Color$2 = class Color {
|
|
1546
1541
|
constructor(red, green, blue, alpha) {
|
|
1547
1542
|
this.red = red;
|
|
@@ -1550,7 +1545,9 @@ let Color$2 = class Color {
|
|
|
1550
1545
|
this.alpha = alpha;
|
|
1551
1546
|
}
|
|
1552
1547
|
};
|
|
1553
|
-
Color$2 =
|
|
1548
|
+
Color$2 = __decorate([
|
|
1549
|
+
es5ClassCompat
|
|
1550
|
+
], Color$2);
|
|
1554
1551
|
let ColorInformation$1 = class ColorInformation {
|
|
1555
1552
|
constructor(range, color) {
|
|
1556
1553
|
if (color && !(color instanceof Color$2)) {
|
|
@@ -1563,7 +1560,9 @@ let ColorInformation$1 = class ColorInformation {
|
|
|
1563
1560
|
this.color = color;
|
|
1564
1561
|
}
|
|
1565
1562
|
};
|
|
1566
|
-
ColorInformation$1 =
|
|
1563
|
+
ColorInformation$1 = __decorate([
|
|
1564
|
+
es5ClassCompat
|
|
1565
|
+
], ColorInformation$1);
|
|
1567
1566
|
let ColorPresentation$2 = class ColorPresentation {
|
|
1568
1567
|
constructor(label) {
|
|
1569
1568
|
if (!label || typeof label !== 'string') {
|
|
@@ -1572,7 +1571,9 @@ let ColorPresentation$2 = class ColorPresentation {
|
|
|
1572
1571
|
this.label = label;
|
|
1573
1572
|
}
|
|
1574
1573
|
};
|
|
1575
|
-
ColorPresentation$2 =
|
|
1574
|
+
ColorPresentation$2 = __decorate([
|
|
1575
|
+
es5ClassCompat
|
|
1576
|
+
], ColorPresentation$2);
|
|
1576
1577
|
class TerminalLink$1 {
|
|
1577
1578
|
constructor(startIndex, length, tooltip) {
|
|
1578
1579
|
this.startIndex = startIndex;
|
|
@@ -1647,7 +1648,9 @@ TaskGroup$1.Clean = new TaskGroup_1('clean', 'Clean');
|
|
|
1647
1648
|
TaskGroup$1.Build = new TaskGroup_1('build', 'Build');
|
|
1648
1649
|
TaskGroup$1.Rebuild = new TaskGroup_1('rebuild', 'Rebuild');
|
|
1649
1650
|
TaskGroup$1.Test = new TaskGroup_1('test', 'Test');
|
|
1650
|
-
TaskGroup$1 = TaskGroup_1 =
|
|
1651
|
+
TaskGroup$1 = TaskGroup_1 = __decorate([
|
|
1652
|
+
es5ClassCompat
|
|
1653
|
+
], TaskGroup$1);
|
|
1651
1654
|
function computeTaskExecutionId(values) {
|
|
1652
1655
|
let id = '';
|
|
1653
1656
|
for (let i = 0; i < values.length; i++) {
|
|
@@ -1710,7 +1713,9 @@ let ProcessExecution$1 = class ProcessExecution {
|
|
|
1710
1713
|
return computeTaskExecutionId(props);
|
|
1711
1714
|
}
|
|
1712
1715
|
};
|
|
1713
|
-
ProcessExecution$1 =
|
|
1716
|
+
ProcessExecution$1 = __decorate([
|
|
1717
|
+
es5ClassCompat
|
|
1718
|
+
], ProcessExecution$1);
|
|
1714
1719
|
let ShellExecution$1 = class ShellExecution {
|
|
1715
1720
|
constructor(arg0, arg1, arg2) {
|
|
1716
1721
|
this._args = [];
|
|
@@ -1780,7 +1785,9 @@ let ShellExecution$1 = class ShellExecution {
|
|
|
1780
1785
|
return computeTaskExecutionId(props);
|
|
1781
1786
|
}
|
|
1782
1787
|
};
|
|
1783
|
-
ShellExecution$1 =
|
|
1788
|
+
ShellExecution$1 = __decorate([
|
|
1789
|
+
es5ClassCompat
|
|
1790
|
+
], ShellExecution$1);
|
|
1784
1791
|
var ShellQuoting$1;
|
|
1785
1792
|
(function(ShellQuoting) {
|
|
1786
1793
|
ShellQuoting[ShellQuoting["Escape"] = 1] = "Escape";
|
|
@@ -2015,7 +2022,9 @@ Task$1.ExtensionCallbackType = 'customExecution';
|
|
|
2015
2022
|
Task$1.ProcessType = 'process';
|
|
2016
2023
|
Task$1.ShellType = 'shell';
|
|
2017
2024
|
Task$1.EmptyType = '$empty';
|
|
2018
|
-
Task$1 = Task_1 =
|
|
2025
|
+
Task$1 = Task_1 = __decorate([
|
|
2026
|
+
es5ClassCompat
|
|
2027
|
+
], Task$1);
|
|
2019
2028
|
var ProgressLocation$2;
|
|
2020
2029
|
(function(ProgressLocation) {
|
|
2021
2030
|
ProgressLocation[ProgressLocation["SourceControl"] = 1] = "SourceControl";
|
|
@@ -2033,7 +2042,9 @@ let TreeItem$1 = class TreeItem {
|
|
|
2033
2042
|
}
|
|
2034
2043
|
}
|
|
2035
2044
|
};
|
|
2036
|
-
TreeItem$1 =
|
|
2045
|
+
TreeItem$1 = __decorate([
|
|
2046
|
+
es5ClassCompat
|
|
2047
|
+
], TreeItem$1);
|
|
2037
2048
|
var TreeItemCollapsibleState$1;
|
|
2038
2049
|
(function(TreeItemCollapsibleState) {
|
|
2039
2050
|
TreeItemCollapsibleState[TreeItemCollapsibleState["None"] = 0] = "None";
|
|
@@ -2046,7 +2057,9 @@ let ThemeIcon$1 = class ThemeIcon {
|
|
|
2046
2057
|
this.color = color;
|
|
2047
2058
|
}
|
|
2048
2059
|
};
|
|
2049
|
-
ThemeIcon$1 =
|
|
2060
|
+
ThemeIcon$1 = __decorate([
|
|
2061
|
+
es5ClassCompat
|
|
2062
|
+
], ThemeIcon$1);
|
|
2050
2063
|
ThemeIcon$1.File = new ThemeIcon$1('file');
|
|
2051
2064
|
ThemeIcon$1.Folder = new ThemeIcon$1('folder');
|
|
2052
2065
|
let ThemeColor$1 = class ThemeColor {
|
|
@@ -2054,7 +2067,9 @@ let ThemeColor$1 = class ThemeColor {
|
|
|
2054
2067
|
this.id = id;
|
|
2055
2068
|
}
|
|
2056
2069
|
};
|
|
2057
|
-
ThemeColor$1 =
|
|
2070
|
+
ThemeColor$1 = __decorate([
|
|
2071
|
+
es5ClassCompat
|
|
2072
|
+
], ThemeColor$1);
|
|
2058
2073
|
var ConfigurationTarget$1;
|
|
2059
2074
|
(function(ConfigurationTarget) {
|
|
2060
2075
|
ConfigurationTarget[ConfigurationTarget["Global"] = 1] = "Global";
|
|
@@ -2104,7 +2119,9 @@ let RelativePattern$1 = class RelativePattern {
|
|
|
2104
2119
|
};
|
|
2105
2120
|
}
|
|
2106
2121
|
};
|
|
2107
|
-
RelativePattern$1 =
|
|
2122
|
+
RelativePattern$1 = __decorate([
|
|
2123
|
+
es5ClassCompat
|
|
2124
|
+
], RelativePattern$1);
|
|
2108
2125
|
let Breakpoint$1 = class Breakpoint {
|
|
2109
2126
|
constructor(enabled, condition, hitCondition, logMessage) {
|
|
2110
2127
|
this.enabled = typeof enabled === 'boolean' ? enabled : true;
|
|
@@ -2125,7 +2142,9 @@ let Breakpoint$1 = class Breakpoint {
|
|
|
2125
2142
|
return this._id;
|
|
2126
2143
|
}
|
|
2127
2144
|
};
|
|
2128
|
-
Breakpoint$1 =
|
|
2145
|
+
Breakpoint$1 = __decorate([
|
|
2146
|
+
es5ClassCompat
|
|
2147
|
+
], Breakpoint$1);
|
|
2129
2148
|
let SourceBreakpoint$1 = class SourceBreakpoint extends Breakpoint$1 {
|
|
2130
2149
|
constructor(location, enabled, condition, hitCondition, logMessage) {
|
|
2131
2150
|
super(enabled, condition, hitCondition, logMessage);
|
|
@@ -2135,14 +2154,18 @@ let SourceBreakpoint$1 = class SourceBreakpoint extends Breakpoint$1 {
|
|
|
2135
2154
|
this.location = location;
|
|
2136
2155
|
}
|
|
2137
2156
|
};
|
|
2138
|
-
SourceBreakpoint$1 =
|
|
2157
|
+
SourceBreakpoint$1 = __decorate([
|
|
2158
|
+
es5ClassCompat
|
|
2159
|
+
], SourceBreakpoint$1);
|
|
2139
2160
|
let FunctionBreakpoint$1 = class FunctionBreakpoint extends Breakpoint$1 {
|
|
2140
2161
|
constructor(functionName, enabled, condition, hitCondition, logMessage) {
|
|
2141
2162
|
super(enabled, condition, hitCondition, logMessage);
|
|
2142
2163
|
this.functionName = functionName;
|
|
2143
2164
|
}
|
|
2144
2165
|
};
|
|
2145
|
-
FunctionBreakpoint$1 =
|
|
2166
|
+
FunctionBreakpoint$1 = __decorate([
|
|
2167
|
+
es5ClassCompat
|
|
2168
|
+
], FunctionBreakpoint$1);
|
|
2146
2169
|
let DebugAdapterExecutable$1 = class DebugAdapterExecutable {
|
|
2147
2170
|
constructor(command, args, options) {
|
|
2148
2171
|
this.command = command;
|
|
@@ -2150,40 +2173,52 @@ let DebugAdapterExecutable$1 = class DebugAdapterExecutable {
|
|
|
2150
2173
|
this.options = options;
|
|
2151
2174
|
}
|
|
2152
2175
|
};
|
|
2153
|
-
DebugAdapterExecutable$1 =
|
|
2176
|
+
DebugAdapterExecutable$1 = __decorate([
|
|
2177
|
+
es5ClassCompat
|
|
2178
|
+
], DebugAdapterExecutable$1);
|
|
2154
2179
|
let DebugAdapterServer$1 = class DebugAdapterServer {
|
|
2155
2180
|
constructor(port, host) {
|
|
2156
2181
|
this.port = port;
|
|
2157
2182
|
this.host = host;
|
|
2158
2183
|
}
|
|
2159
2184
|
};
|
|
2160
|
-
DebugAdapterServer$1 =
|
|
2185
|
+
DebugAdapterServer$1 = __decorate([
|
|
2186
|
+
es5ClassCompat
|
|
2187
|
+
], DebugAdapterServer$1);
|
|
2161
2188
|
let DebugAdapterNamedPipeServer$1 = class DebugAdapterNamedPipeServer {
|
|
2162
2189
|
constructor(path) {
|
|
2163
2190
|
this.path = path;
|
|
2164
2191
|
}
|
|
2165
2192
|
};
|
|
2166
|
-
DebugAdapterNamedPipeServer$1 =
|
|
2193
|
+
DebugAdapterNamedPipeServer$1 = __decorate([
|
|
2194
|
+
es5ClassCompat
|
|
2195
|
+
], DebugAdapterNamedPipeServer$1);
|
|
2167
2196
|
let DebugAdapterInlineImplementation$1 = class DebugAdapterInlineImplementation {
|
|
2168
2197
|
constructor(impl) {
|
|
2169
2198
|
this.implementation = impl;
|
|
2170
2199
|
}
|
|
2171
2200
|
};
|
|
2172
|
-
DebugAdapterInlineImplementation$1 =
|
|
2201
|
+
DebugAdapterInlineImplementation$1 = __decorate([
|
|
2202
|
+
es5ClassCompat
|
|
2203
|
+
], DebugAdapterInlineImplementation$1);
|
|
2173
2204
|
let EvaluatableExpression$2 = class EvaluatableExpression {
|
|
2174
2205
|
constructor(range, expression) {
|
|
2175
2206
|
this.range = range;
|
|
2176
2207
|
this.expression = expression;
|
|
2177
2208
|
}
|
|
2178
2209
|
};
|
|
2179
|
-
EvaluatableExpression$2 =
|
|
2210
|
+
EvaluatableExpression$2 = __decorate([
|
|
2211
|
+
es5ClassCompat
|
|
2212
|
+
], EvaluatableExpression$2);
|
|
2180
2213
|
let InlineValueText$1 = class InlineValueText {
|
|
2181
2214
|
constructor(range, text) {
|
|
2182
2215
|
this.range = range;
|
|
2183
2216
|
this.text = text;
|
|
2184
2217
|
}
|
|
2185
2218
|
};
|
|
2186
|
-
InlineValueText$1 =
|
|
2219
|
+
InlineValueText$1 = __decorate([
|
|
2220
|
+
es5ClassCompat
|
|
2221
|
+
], InlineValueText$1);
|
|
2187
2222
|
let InlineValueVariableLookup$1 = class InlineValueVariableLookup {
|
|
2188
2223
|
constructor(range, variableName, caseSensitiveLookup = true) {
|
|
2189
2224
|
this.range = range;
|
|
@@ -2191,21 +2226,27 @@ let InlineValueVariableLookup$1 = class InlineValueVariableLookup {
|
|
|
2191
2226
|
this.caseSensitiveLookup = caseSensitiveLookup;
|
|
2192
2227
|
}
|
|
2193
2228
|
};
|
|
2194
|
-
InlineValueVariableLookup$1 =
|
|
2229
|
+
InlineValueVariableLookup$1 = __decorate([
|
|
2230
|
+
es5ClassCompat
|
|
2231
|
+
], InlineValueVariableLookup$1);
|
|
2195
2232
|
let InlineValueEvaluatableExpression$1 = class InlineValueEvaluatableExpression {
|
|
2196
2233
|
constructor(range, expression) {
|
|
2197
2234
|
this.range = range;
|
|
2198
2235
|
this.expression = expression;
|
|
2199
2236
|
}
|
|
2200
2237
|
};
|
|
2201
|
-
InlineValueEvaluatableExpression$1 =
|
|
2238
|
+
InlineValueEvaluatableExpression$1 = __decorate([
|
|
2239
|
+
es5ClassCompat
|
|
2240
|
+
], InlineValueEvaluatableExpression$1);
|
|
2202
2241
|
let InlineValueContext$1 = class InlineValueContext {
|
|
2203
2242
|
constructor(frameId, range) {
|
|
2204
2243
|
this.frameId = frameId;
|
|
2205
2244
|
this.stoppedLocation = range;
|
|
2206
2245
|
}
|
|
2207
2246
|
};
|
|
2208
|
-
InlineValueContext$1 =
|
|
2247
|
+
InlineValueContext$1 = __decorate([
|
|
2248
|
+
es5ClassCompat
|
|
2249
|
+
], InlineValueContext$1);
|
|
2209
2250
|
var FileChangeType$1;
|
|
2210
2251
|
(function(FileChangeType) {
|
|
2211
2252
|
FileChangeType[FileChangeType["Changed"] = 1] = "Changed";
|
|
@@ -2279,7 +2320,9 @@ let FileSystemError$1 = FileSystemError_1 = class FileSystemError extends Error
|
|
|
2279
2320
|
);
|
|
2280
2321
|
}
|
|
2281
2322
|
};
|
|
2282
|
-
FileSystemError$1 = FileSystemError_1 =
|
|
2323
|
+
FileSystemError$1 = FileSystemError_1 = __decorate([
|
|
2324
|
+
es5ClassCompat
|
|
2325
|
+
], FileSystemError$1);
|
|
2283
2326
|
let FoldingRange$2 = class FoldingRange {
|
|
2284
2327
|
constructor(start, end, kind) {
|
|
2285
2328
|
this.start = start;
|
|
@@ -2287,7 +2330,9 @@ let FoldingRange$2 = class FoldingRange {
|
|
|
2287
2330
|
this.kind = kind;
|
|
2288
2331
|
}
|
|
2289
2332
|
};
|
|
2290
|
-
FoldingRange$2 =
|
|
2333
|
+
FoldingRange$2 = __decorate([
|
|
2334
|
+
es5ClassCompat
|
|
2335
|
+
], FoldingRange$2);
|
|
2291
2336
|
var FoldingRangeKind$3;
|
|
2292
2337
|
(function(FoldingRangeKind) {
|
|
2293
2338
|
FoldingRangeKind[FoldingRangeKind["Comment"] = 1] = "Comment";
|
|
@@ -2487,7 +2532,9 @@ let QuickInputButtons$1 = class QuickInputButtons {
|
|
|
2487
2532
|
constructor() { }
|
|
2488
2533
|
};
|
|
2489
2534
|
QuickInputButtons$1.Back = { iconPath: new ThemeIcon$1('arrow-left') };
|
|
2490
|
-
QuickInputButtons$1 =
|
|
2535
|
+
QuickInputButtons$1 = __decorate([
|
|
2536
|
+
es5ClassCompat
|
|
2537
|
+
], QuickInputButtons$1);
|
|
2491
2538
|
var QuickPickItemKind$1;
|
|
2492
2539
|
(function(QuickPickItemKind) {
|
|
2493
2540
|
QuickPickItemKind[QuickPickItemKind["Separator"] = -1] = "Separator";
|
|
@@ -2711,13 +2758,6 @@ var NotebookCellStatusBarAlignment$1;
|
|
|
2711
2758
|
NotebookCellStatusBarAlignment[NotebookCellStatusBarAlignment["Left"] = 1] = "Left";
|
|
2712
2759
|
NotebookCellStatusBarAlignment[NotebookCellStatusBarAlignment["Right"] = 2] = "Right";
|
|
2713
2760
|
})(NotebookCellStatusBarAlignment$1 || (NotebookCellStatusBarAlignment$1 = {}));
|
|
2714
|
-
var NotebookEditorRevealType$1;
|
|
2715
|
-
(function(NotebookEditorRevealType) {
|
|
2716
|
-
NotebookEditorRevealType[NotebookEditorRevealType["Default"] = 0] = "Default";
|
|
2717
|
-
NotebookEditorRevealType[NotebookEditorRevealType["InCenter"] = 1] = "InCenter";
|
|
2718
|
-
NotebookEditorRevealType[NotebookEditorRevealType["InCenterIfOutsideViewport"] = 2] = "InCenterIfOutsideViewport";
|
|
2719
|
-
NotebookEditorRevealType[NotebookEditorRevealType["AtTop"] = 3] = "AtTop";
|
|
2720
|
-
})(NotebookEditorRevealType$1 || (NotebookEditorRevealType$1 = {}));
|
|
2721
2761
|
class NotebookCellStatusBarItem$1 {
|
|
2722
2762
|
constructor(text, alignment) {
|
|
2723
2763
|
this.text = text;
|
|
@@ -2761,7 +2801,9 @@ let TestRunRequest$1 = class TestRunRequest {
|
|
|
2761
2801
|
this.profile = profile;
|
|
2762
2802
|
}
|
|
2763
2803
|
};
|
|
2764
|
-
TestRunRequest$1 =
|
|
2804
|
+
TestRunRequest$1 = __decorate([
|
|
2805
|
+
es5ClassCompat
|
|
2806
|
+
], TestRunRequest$1);
|
|
2765
2807
|
let TestMessage$1 = TestMessage_1 = class TestMessage {
|
|
2766
2808
|
constructor(message) {
|
|
2767
2809
|
this.message = message;
|
|
@@ -2773,13 +2815,17 @@ let TestMessage$1 = TestMessage_1 = class TestMessage {
|
|
|
2773
2815
|
return msg;
|
|
2774
2816
|
}
|
|
2775
2817
|
};
|
|
2776
|
-
TestMessage$1 = TestMessage_1 =
|
|
2818
|
+
TestMessage$1 = TestMessage_1 = __decorate([
|
|
2819
|
+
es5ClassCompat
|
|
2820
|
+
], TestMessage$1);
|
|
2777
2821
|
let TestTag$1 = class TestTag {
|
|
2778
2822
|
constructor(id) {
|
|
2779
2823
|
this.id = id;
|
|
2780
2824
|
}
|
|
2781
2825
|
};
|
|
2782
|
-
TestTag$1 =
|
|
2826
|
+
TestTag$1 = __decorate([
|
|
2827
|
+
es5ClassCompat
|
|
2828
|
+
], TestTag$1);
|
|
2783
2829
|
class TypeHierarchyItem$2 {
|
|
2784
2830
|
constructor(kind, name, detail, uri, range, selectionRange) {
|
|
2785
2831
|
this.kind = kind;
|
|
@@ -2802,72 +2848,6 @@ var UIKind$1;
|
|
|
2802
2848
|
UIKind[UIKind["Desktop"] = 1] = "Desktop";
|
|
2803
2849
|
UIKind[UIKind["Web"] = 2] = "Web";
|
|
2804
2850
|
})(UIKind$1 || (UIKind$1 = {}));
|
|
2805
|
-
const Emitter = monaco.Emitter;
|
|
2806
|
-
function equals(one, other) {
|
|
2807
|
-
if (one === other) {
|
|
2808
|
-
return true;
|
|
2809
|
-
}
|
|
2810
|
-
if (one === null || one === undefined || other === null || other === undefined) {
|
|
2811
|
-
return false;
|
|
2812
|
-
}
|
|
2813
|
-
if (typeof one !== typeof other) {
|
|
2814
|
-
return false;
|
|
2815
|
-
}
|
|
2816
|
-
if (typeof one !== 'object') {
|
|
2817
|
-
return false;
|
|
2818
|
-
}
|
|
2819
|
-
if ((Array.isArray(one)) !== (Array.isArray(other))) {
|
|
2820
|
-
return false;
|
|
2821
|
-
}
|
|
2822
|
-
let i;
|
|
2823
|
-
let key;
|
|
2824
|
-
if (Array.isArray(one)) {
|
|
2825
|
-
if (one.length !== other.length) {
|
|
2826
|
-
return false;
|
|
2827
|
-
}
|
|
2828
|
-
for (i = 0; i < one.length; i++) {
|
|
2829
|
-
if (!equals(one[i], other[i])) {
|
|
2830
|
-
return false;
|
|
2831
|
-
}
|
|
2832
|
-
}
|
|
2833
|
-
}
|
|
2834
|
-
else {
|
|
2835
|
-
const oneKeys = [];
|
|
2836
|
-
for (key in one) {
|
|
2837
|
-
oneKeys.push(key);
|
|
2838
|
-
}
|
|
2839
|
-
oneKeys.sort();
|
|
2840
|
-
const otherKeys = [];
|
|
2841
|
-
for (key in other) {
|
|
2842
|
-
otherKeys.push(key);
|
|
2843
|
-
}
|
|
2844
|
-
otherKeys.sort();
|
|
2845
|
-
if (!equals(oneKeys, otherKeys)) {
|
|
2846
|
-
return false;
|
|
2847
|
-
}
|
|
2848
|
-
for (i = 0; i < oneKeys.length; i++) {
|
|
2849
|
-
if (!equals(one[oneKeys[i]], other[oneKeys[i]])) {
|
|
2850
|
-
return false;
|
|
2851
|
-
}
|
|
2852
|
-
}
|
|
2853
|
-
}
|
|
2854
|
-
return true;
|
|
2855
|
-
}
|
|
2856
|
-
function distinct(base, target) {
|
|
2857
|
-
const result = Object.create(null);
|
|
2858
|
-
if (!base || !target) {
|
|
2859
|
-
return result;
|
|
2860
|
-
}
|
|
2861
|
-
const targetKeys = Object.keys(target);
|
|
2862
|
-
targetKeys.forEach(k => {
|
|
2863
|
-
const baseValue = base[k];
|
|
2864
|
-
const targetValue = target[k];
|
|
2865
|
-
if (!equals(baseValue, targetValue)) {
|
|
2866
|
-
result[k] = targetValue;
|
|
2867
|
-
}
|
|
2868
|
-
});
|
|
2869
|
-
return result;
|
|
2870
|
-
}
|
|
2871
2851
|
var TextEditorCursorStyle$1;
|
|
2872
2852
|
(function(TextEditorCursorStyle) {
|
|
2873
2853
|
TextEditorCursorStyle[TextEditorCursorStyle["Line"] = 1] = "Line";
|
|
@@ -2902,209 +2882,11 @@ var EditorResolution;
|
|
|
2902
2882
|
EditorResolution[EditorResolution["DISABLED"] = 1] = "DISABLED";
|
|
2903
2883
|
EditorResolution[EditorResolution["EXCLUSIVE_ONLY"] = 2] = "EXCLUSIVE_ONLY";
|
|
2904
2884
|
})(EditorResolution || (EditorResolution = {}));
|
|
2905
|
-
function isThenable(obj) {
|
|
2906
|
-
return !!obj && typeof obj.then === 'function';
|
|
2907
|
-
}
|
|
2908
|
-
function raceCancellationError(promise, token) {
|
|
2909
|
-
return (
|
|
2910
|
-
new Promise((resolve, reject) => {
|
|
2911
|
-
const ref = token.onCancellationRequested(() => {
|
|
2912
|
-
ref.dispose();
|
|
2913
|
-
reject( new CancellationError$1());
|
|
2914
|
-
});
|
|
2915
|
-
promise.then(resolve, reject).finally(() => ref.dispose());
|
|
2916
|
-
})
|
|
2917
|
-
);
|
|
2918
|
-
}
|
|
2919
|
-
function asPromise(callback) {
|
|
2920
|
-
return (
|
|
2921
|
-
new Promise((resolve, reject) => {
|
|
2922
|
-
const item = callback();
|
|
2923
|
-
if (isThenable(item)) {
|
|
2924
|
-
item.then(resolve, reject);
|
|
2925
|
-
}
|
|
2926
|
-
else {
|
|
2927
|
-
resolve(item);
|
|
2928
|
-
}
|
|
2929
|
-
})
|
|
2930
|
-
);
|
|
2931
|
-
}
|
|
2932
2885
|
var CellKind;
|
|
2933
2886
|
(function(CellKind) {
|
|
2934
2887
|
CellKind[CellKind["Markup"] = 1] = "Markup";
|
|
2935
2888
|
CellKind[CellKind["Code"] = 2] = "Code";
|
|
2936
2889
|
})(CellKind || (CellKind = {}));
|
|
2937
|
-
const EditorExtensions = {
|
|
2938
|
-
EditorPane: 'workbench.contributions.editors',
|
|
2939
|
-
EditorFactory: 'workbench.contributions.editor.inputFactories'
|
|
2940
|
-
};
|
|
2941
|
-
function isResourceDiffEditorInput(editor) {
|
|
2942
|
-
if (isEditorInput(editor)) {
|
|
2943
|
-
return false;
|
|
2944
|
-
}
|
|
2945
|
-
const candidate = editor;
|
|
2946
|
-
return candidate?.original !== undefined && candidate.modified !== undefined;
|
|
2947
|
-
}
|
|
2948
|
-
function isResourceSideBySideEditorInput(editor) {
|
|
2949
|
-
if (isEditorInput(editor)) {
|
|
2950
|
-
return false;
|
|
2951
|
-
}
|
|
2952
|
-
if (isResourceDiffEditorInput(editor)) {
|
|
2953
|
-
return false;
|
|
2954
|
-
}
|
|
2955
|
-
const candidate = editor;
|
|
2956
|
-
return candidate?.primary !== undefined && candidate.secondary !== undefined;
|
|
2957
|
-
}
|
|
2958
|
-
class AbstractEditorInput extends Disposable$2 {
|
|
2959
|
-
}
|
|
2960
|
-
function isEditorInput(editor) {
|
|
2961
|
-
return editor instanceof AbstractEditorInput;
|
|
2962
|
-
}
|
|
2963
|
-
function isEditorInputWithPreferredResource(editor) {
|
|
2964
|
-
const candidate = editor;
|
|
2965
|
-
return URI.isUri(candidate?.preferredResource);
|
|
2966
|
-
}
|
|
2967
|
-
function isSideBySideEditorInput(editor) {
|
|
2968
|
-
const candidate = editor;
|
|
2969
|
-
return isEditorInput(candidate?.primary) && isEditorInput(candidate?.secondary);
|
|
2970
|
-
}
|
|
2971
|
-
function isDiffEditorInput(editor) {
|
|
2972
|
-
const candidate = editor;
|
|
2973
|
-
return isEditorInput(candidate?.modified) && isEditorInput(candidate?.original);
|
|
2974
|
-
}
|
|
2975
|
-
var SideBySideEditor;
|
|
2976
|
-
(function(SideBySideEditor) {
|
|
2977
|
-
SideBySideEditor[SideBySideEditor["PRIMARY"] = 1] = "PRIMARY";
|
|
2978
|
-
SideBySideEditor[SideBySideEditor["SECONDARY"] = 2] = "SECONDARY";
|
|
2979
|
-
SideBySideEditor[SideBySideEditor["BOTH"] = 3] = "BOTH";
|
|
2980
|
-
SideBySideEditor[SideBySideEditor["ANY"] = 4] = "ANY";
|
|
2981
|
-
})(SideBySideEditor || (SideBySideEditor = {}));
|
|
2982
|
-
class EditorResourceAccessorImpl {
|
|
2983
|
-
getOriginalUri(editor, options) {
|
|
2984
|
-
if (!editor) {
|
|
2985
|
-
return undefined;
|
|
2986
|
-
}
|
|
2987
|
-
if (options?.supportSideBySide) {
|
|
2988
|
-
const { primary, secondary } = this.getSideEditors(editor);
|
|
2989
|
-
if (primary && secondary) {
|
|
2990
|
-
if (options?.supportSideBySide === SideBySideEditor.BOTH) {
|
|
2991
|
-
return {
|
|
2992
|
-
primary: this.getOriginalUri(primary, { filterByScheme: options.filterByScheme }),
|
|
2993
|
-
secondary: this.getOriginalUri(secondary, { filterByScheme: options.filterByScheme })
|
|
2994
|
-
};
|
|
2995
|
-
}
|
|
2996
|
-
else if (options?.supportSideBySide === SideBySideEditor.ANY) {
|
|
2997
|
-
return this.getOriginalUri(primary, { filterByScheme: options.filterByScheme }) ?? this.getOriginalUri(secondary, { filterByScheme: options.filterByScheme });
|
|
2998
|
-
}
|
|
2999
|
-
editor = options.supportSideBySide === SideBySideEditor.PRIMARY ? primary : secondary;
|
|
3000
|
-
}
|
|
3001
|
-
}
|
|
3002
|
-
if (isResourceDiffEditorInput(editor) || isResourceSideBySideEditorInput(editor)) {
|
|
3003
|
-
return;
|
|
3004
|
-
}
|
|
3005
|
-
const originalResource = isEditorInputWithPreferredResource(editor) ? editor.preferredResource : editor.resource;
|
|
3006
|
-
if (!originalResource || !options || !options.filterByScheme) {
|
|
3007
|
-
return originalResource;
|
|
3008
|
-
}
|
|
3009
|
-
return this.filterUri(originalResource, options.filterByScheme);
|
|
3010
|
-
}
|
|
3011
|
-
getSideEditors(editor) {
|
|
3012
|
-
if (isSideBySideEditorInput(editor) || isResourceSideBySideEditorInput(editor)) {
|
|
3013
|
-
return { primary: editor.primary, secondary: editor.secondary };
|
|
3014
|
-
}
|
|
3015
|
-
if (isDiffEditorInput(editor) || isResourceDiffEditorInput(editor)) {
|
|
3016
|
-
return { primary: editor.modified, secondary: editor.original };
|
|
3017
|
-
}
|
|
3018
|
-
return { primary: undefined, secondary: undefined };
|
|
3019
|
-
}
|
|
3020
|
-
getCanonicalUri(editor, options) {
|
|
3021
|
-
if (!editor) {
|
|
3022
|
-
return undefined;
|
|
3023
|
-
}
|
|
3024
|
-
if (options?.supportSideBySide) {
|
|
3025
|
-
const { primary, secondary } = this.getSideEditors(editor);
|
|
3026
|
-
if (primary && secondary) {
|
|
3027
|
-
if (options?.supportSideBySide === SideBySideEditor.BOTH) {
|
|
3028
|
-
return {
|
|
3029
|
-
primary: this.getCanonicalUri(primary, { filterByScheme: options.filterByScheme }),
|
|
3030
|
-
secondary: this.getCanonicalUri(secondary, { filterByScheme: options.filterByScheme })
|
|
3031
|
-
};
|
|
3032
|
-
}
|
|
3033
|
-
else if (options?.supportSideBySide === SideBySideEditor.ANY) {
|
|
3034
|
-
return this.getCanonicalUri(primary, { filterByScheme: options.filterByScheme }) ?? this.getCanonicalUri(secondary, { filterByScheme: options.filterByScheme });
|
|
3035
|
-
}
|
|
3036
|
-
editor = options.supportSideBySide === SideBySideEditor.PRIMARY ? primary : secondary;
|
|
3037
|
-
}
|
|
3038
|
-
}
|
|
3039
|
-
if (isResourceDiffEditorInput(editor) || isResourceSideBySideEditorInput(editor)) {
|
|
3040
|
-
return;
|
|
3041
|
-
}
|
|
3042
|
-
const canonicalResource = editor.resource;
|
|
3043
|
-
if (!canonicalResource || !options || !options.filterByScheme) {
|
|
3044
|
-
return canonicalResource;
|
|
3045
|
-
}
|
|
3046
|
-
return this.filterUri(canonicalResource, options.filterByScheme);
|
|
3047
|
-
}
|
|
3048
|
-
filterUri(resource, filter) {
|
|
3049
|
-
if (Array.isArray(filter)) {
|
|
3050
|
-
if (filter.some(scheme => resource.scheme === scheme)) {
|
|
3051
|
-
return resource;
|
|
3052
|
-
}
|
|
3053
|
-
}
|
|
3054
|
-
else {
|
|
3055
|
-
if (filter === resource.scheme) {
|
|
3056
|
-
return resource;
|
|
3057
|
-
}
|
|
3058
|
-
}
|
|
3059
|
-
return undefined;
|
|
3060
|
-
}
|
|
3061
|
-
}
|
|
3062
|
-
const EditorResourceAccessor = new EditorResourceAccessorImpl();
|
|
3063
|
-
class EditorFactoryRegistry {
|
|
3064
|
-
constructor() {
|
|
3065
|
-
this.editorSerializerConstructors = new Map();
|
|
3066
|
-
this.editorSerializerInstances = new Map();
|
|
3067
|
-
}
|
|
3068
|
-
start(accessor) {
|
|
3069
|
-
const instantiationService = this.instantiationService = accessor.get(IInstantiationService);
|
|
3070
|
-
for (const [key, ctor] of this.editorSerializerConstructors) {
|
|
3071
|
-
this.createEditorSerializer(key, ctor, instantiationService);
|
|
3072
|
-
}
|
|
3073
|
-
this.editorSerializerConstructors.clear();
|
|
3074
|
-
}
|
|
3075
|
-
createEditorSerializer(editorTypeId, ctor, instantiationService) {
|
|
3076
|
-
const instance = instantiationService.createInstance(ctor);
|
|
3077
|
-
this.editorSerializerInstances.set(editorTypeId, instance);
|
|
3078
|
-
}
|
|
3079
|
-
registerFileEditorFactory(factory) {
|
|
3080
|
-
if (this.fileEditorFactory) {
|
|
3081
|
-
throw new Error('Can only register one file editor factory.');
|
|
3082
|
-
}
|
|
3083
|
-
this.fileEditorFactory = factory;
|
|
3084
|
-
}
|
|
3085
|
-
getFileEditorFactory() {
|
|
3086
|
-
return assertIsDefined(this.fileEditorFactory);
|
|
3087
|
-
}
|
|
3088
|
-
registerEditorSerializer(editorTypeId, ctor) {
|
|
3089
|
-
if (this.editorSerializerConstructors.has(editorTypeId) || this.editorSerializerInstances.has(editorTypeId)) {
|
|
3090
|
-
throw new Error(`A editor serializer with type ID '${editorTypeId}' was already registered.`);
|
|
3091
|
-
}
|
|
3092
|
-
if (!this.instantiationService) {
|
|
3093
|
-
this.editorSerializerConstructors.set(editorTypeId, ctor);
|
|
3094
|
-
}
|
|
3095
|
-
else {
|
|
3096
|
-
this.createEditorSerializer(editorTypeId, ctor, this.instantiationService);
|
|
3097
|
-
}
|
|
3098
|
-
return toDisposable(() => {
|
|
3099
|
-
this.editorSerializerConstructors.delete(editorTypeId);
|
|
3100
|
-
this.editorSerializerInstances.delete(editorTypeId);
|
|
3101
|
-
});
|
|
3102
|
-
}
|
|
3103
|
-
getEditorSerializer(arg1) {
|
|
3104
|
-
return this.editorSerializerInstances.get(typeof arg1 === 'string' ? arg1 : arg1.typeId);
|
|
3105
|
-
}
|
|
3106
|
-
}
|
|
3107
|
-
Registry.add(EditorExtensions.EditorFactory, new EditorFactoryRegistry());
|
|
3108
2890
|
var Selection$2;
|
|
3109
2891
|
(function(Selection) {
|
|
3110
2892
|
function to(selection) {
|
|
@@ -3233,7 +3015,7 @@ var Diagnostic$1;
|
|
|
3233
3015
|
function from(value) {
|
|
3234
3016
|
let code;
|
|
3235
3017
|
if (value.code) {
|
|
3236
|
-
if (isString
|
|
3018
|
+
if (isString(value.code) || isNumber(value.code)) {
|
|
3237
3019
|
code = String(value.code);
|
|
3238
3020
|
}
|
|
3239
3021
|
else {
|
|
@@ -3257,7 +3039,7 @@ var Diagnostic$1;
|
|
|
3257
3039
|
function to(value) {
|
|
3258
3040
|
const res = new Diagnostic$2(Range$1.to(value), value.message, DiagnosticSeverity$1.to(value.severity));
|
|
3259
3041
|
res.source = value.source;
|
|
3260
|
-
res.code = isString
|
|
3042
|
+
res.code = isString(value.code) ? value.code : value.code?.value;
|
|
3261
3043
|
res.relatedInformation = value.relatedInformation && value.relatedInformation.map(DiagnosticRelatedInformation$1.to);
|
|
3262
3044
|
res.tags = value.tags && coalesce(value.tags.map(DiagnosticTag$1.to));
|
|
3263
3045
|
return res;
|
|
@@ -3370,7 +3152,7 @@ var MarkdownString$1;
|
|
|
3370
3152
|
res.uris = resUris;
|
|
3371
3153
|
const collectUri = (href) => {
|
|
3372
3154
|
try {
|
|
3373
|
-
let uri =
|
|
3155
|
+
let uri = URI.parse(href, true);
|
|
3374
3156
|
uri = uri.with({ query: _uriMassage(uri.query, resUris) });
|
|
3375
3157
|
resUris[href] = uri;
|
|
3376
3158
|
}
|
|
@@ -4141,7 +3923,7 @@ var DocumentLink$1;
|
|
|
4141
3923
|
let target = undefined;
|
|
4142
3924
|
if (link.url) {
|
|
4143
3925
|
try {
|
|
4144
|
-
target = typeof link.url === 'string' ?
|
|
3926
|
+
target = typeof link.url === 'string' ? URI.parse(link.url, true) : URI.revive(link.url);
|
|
4145
3927
|
}
|
|
4146
3928
|
catch (err) {
|
|
4147
3929
|
}
|
|
@@ -4754,6 +4536,7 @@ class ConsoleMainLogger extends AbstractLogger {
|
|
|
4754
4536
|
}
|
|
4755
4537
|
}
|
|
4756
4538
|
const Position$1 = monaco.Position;
|
|
4539
|
+
const IExtHostRpcService = createDecorator('IExtHostRpcService');
|
|
4757
4540
|
var _ExtHostCommands_proxy;
|
|
4758
4541
|
let ExtHostCommands = class ExtHostCommands {
|
|
4759
4542
|
constructor(extHostRpc, logService) {
|
|
@@ -4959,7 +4742,10 @@ let ExtHostCommands = class ExtHostCommands {
|
|
|
4959
4742
|
}
|
|
4960
4743
|
};
|
|
4961
4744
|
_ExtHostCommands_proxy = new WeakMap();
|
|
4962
|
-
ExtHostCommands =
|
|
4745
|
+
ExtHostCommands = __decorate([
|
|
4746
|
+
__param(0, IExtHostRpcService),
|
|
4747
|
+
__param(1, ILogService)
|
|
4748
|
+
], ExtHostCommands);
|
|
4963
4749
|
class CommandsConverter {
|
|
4964
4750
|
constructor(_commands, _lookupApiCommand, _logService) {
|
|
4965
4751
|
this._commands = _commands;
|
|
@@ -5033,15 +4819,35 @@ class ApiCommandResult {
|
|
|
5033
4819
|
}
|
|
5034
4820
|
}
|
|
5035
4821
|
ApiCommandResult.Void = new ApiCommandResult('no result', v => v);
|
|
5036
|
-
|
|
5037
|
-
|
|
5038
|
-
|
|
5039
|
-
|
|
5040
|
-
|
|
5041
|
-
|
|
5042
|
-
|
|
5043
|
-
|
|
5044
|
-
|
|
4822
|
+
function extHostNamedCustomer(id) {
|
|
4823
|
+
return function (ctor) {
|
|
4824
|
+
ExtHostCustomersRegistryImpl.INSTANCE.registerNamedCustomer(id, ctor);
|
|
4825
|
+
};
|
|
4826
|
+
}
|
|
4827
|
+
function extHostCustomer(ctor) {
|
|
4828
|
+
ExtHostCustomersRegistryImpl.INSTANCE.registerCustomer(ctor);
|
|
4829
|
+
}
|
|
4830
|
+
class ExtHostCustomersRegistryImpl {
|
|
4831
|
+
constructor() {
|
|
4832
|
+
this._namedCustomers = [];
|
|
4833
|
+
this._customers = [];
|
|
4834
|
+
}
|
|
4835
|
+
registerNamedCustomer(id, ctor) {
|
|
4836
|
+
const entry = [id, ctor];
|
|
4837
|
+
this._namedCustomers.push(entry);
|
|
4838
|
+
}
|
|
4839
|
+
getNamedCustomers() {
|
|
4840
|
+
return this._namedCustomers;
|
|
4841
|
+
}
|
|
4842
|
+
registerCustomer(ctor) {
|
|
4843
|
+
this._customers.push(ctor);
|
|
4844
|
+
}
|
|
4845
|
+
getCustomers() {
|
|
4846
|
+
return this._customers;
|
|
4847
|
+
}
|
|
4848
|
+
}
|
|
4849
|
+
ExtHostCustomersRegistryImpl.INSTANCE = new ExtHostCustomersRegistryImpl();
|
|
4850
|
+
const IExtensionService = createDecorator('extensionService');
|
|
5045
4851
|
function isProposedApiEnabled(extension, proposal) {
|
|
5046
4852
|
if (!extension.enabledApiProposals) {
|
|
5047
4853
|
return false;
|
|
@@ -5138,7 +4944,11 @@ let MainThreadCommands = class MainThreadCommands {
|
|
|
5138
4944
|
return Promise.resolve([...CommandsRegistry.getCommands().keys()]);
|
|
5139
4945
|
}
|
|
5140
4946
|
};
|
|
5141
|
-
MainThreadCommands =
|
|
4947
|
+
MainThreadCommands = __decorate([
|
|
4948
|
+
extHostNamedCustomer(MainContext.MainThreadCommands),
|
|
4949
|
+
__param(1, ICommandService),
|
|
4950
|
+
__param(2, IExtensionService)
|
|
4951
|
+
], MainThreadCommands);
|
|
5142
4952
|
function _generateMarkdown(description) {
|
|
5143
4953
|
if (typeof description === 'string') {
|
|
5144
4954
|
return description;
|
|
@@ -5182,11 +4992,10 @@ let ExtHostApiDeprecationService = class ExtHostApiDeprecationService {
|
|
|
5182
4992
|
return `${apiId}-${extension.identifier.value}`;
|
|
5183
4993
|
}
|
|
5184
4994
|
};
|
|
5185
|
-
ExtHostApiDeprecationService =
|
|
5186
|
-
|
|
5187
|
-
|
|
5188
|
-
|
|
5189
|
-
}());
|
|
4995
|
+
ExtHostApiDeprecationService = __decorate([
|
|
4996
|
+
__param(0, IExtHostRpcService),
|
|
4997
|
+
__param(1, ILogService)
|
|
4998
|
+
], ExtHostApiDeprecationService);
|
|
5190
4999
|
class ExtHostFileSystemInfo {
|
|
5191
5000
|
constructor() {
|
|
5192
5001
|
this._systemSchemes = new Set(Object.keys(Schemas));
|
|
@@ -5217,6 +5026,7 @@ class ExtHostFileSystemInfo {
|
|
|
5217
5026
|
return this._providerInfo.get(scheme);
|
|
5218
5027
|
}
|
|
5219
5028
|
}
|
|
5029
|
+
const IExtHostFileSystemInfo = createDecorator('IExtHostFileSystemInfo');
|
|
5220
5030
|
var _DiagnosticCollection_proxy, _DiagnosticCollection_onDidChangeDiagnostics, _DiagnosticCollection_data;
|
|
5221
5031
|
class DiagnosticCollection {
|
|
5222
5032
|
constructor(_name, _owner, _maxDiagnosticsPerFile, extUri, proxy, onDidChangeDiagnostics) {
|
|
@@ -5357,7 +5167,9 @@ class DiagnosticCollection {
|
|
|
5357
5167
|
this._checkDisposed();
|
|
5358
5168
|
const result = __classPrivateFieldGet(this, _DiagnosticCollection_data, "f").get(uri);
|
|
5359
5169
|
if (Array.isArray(result)) {
|
|
5360
|
-
return
|
|
5170
|
+
return (
|
|
5171
|
+
Object.freeze(result.slice(0))
|
|
5172
|
+
);
|
|
5361
5173
|
}
|
|
5362
5174
|
return [];
|
|
5363
5175
|
}
|
|
@@ -5397,7 +5209,7 @@ let ExtHostDiagnostics = class ExtHostDiagnostics {
|
|
|
5397
5209
|
for (const uri of last) {
|
|
5398
5210
|
map.set(uri, uri);
|
|
5399
5211
|
}
|
|
5400
|
-
return { uris:
|
|
5212
|
+
return { uris: Object.freeze(Array.from(map.values())) };
|
|
5401
5213
|
}
|
|
5402
5214
|
createDiagnosticCollection(extensionId, name) {
|
|
5403
5215
|
const { _collections, _proxy, _onDidChangeDiagnostics, _logService, _fileSystemInfoService } = this;
|
|
@@ -5491,7 +5303,10 @@ let ExtHostDiagnostics = class ExtHostDiagnostics {
|
|
|
5491
5303
|
};
|
|
5492
5304
|
ExtHostDiagnostics._idPool = 0;
|
|
5493
5305
|
ExtHostDiagnostics._maxDiagnosticsPerFile = 1000;
|
|
5494
|
-
ExtHostDiagnostics =
|
|
5306
|
+
ExtHostDiagnostics = __decorate([
|
|
5307
|
+
__param(1, ILogService),
|
|
5308
|
+
__param(2, IExtHostFileSystemInfo)
|
|
5309
|
+
], ExtHostDiagnostics);
|
|
5495
5310
|
function _transformIncomingURIs(obj, transformer, revive, depth) {
|
|
5496
5311
|
if (!obj || depth > 200) {
|
|
5497
5312
|
return null;
|
|
@@ -7257,7 +7072,7 @@ class ExtHostDocumentData extends MirrorTextModel {
|
|
|
7257
7072
|
this._isDirty = false;
|
|
7258
7073
|
}
|
|
7259
7074
|
equalLines(lines) {
|
|
7260
|
-
return equals
|
|
7075
|
+
return equals(this._lines, lines);
|
|
7261
7076
|
}
|
|
7262
7077
|
get document() {
|
|
7263
7078
|
if (!this._document) {
|
|
@@ -7283,7 +7098,9 @@ class ExtHostDocumentData extends MirrorTextModel {
|
|
|
7283
7098
|
getWordRangeAtPosition(pos, regexp) { return that._getWordRangeAtPosition(pos, regexp); },
|
|
7284
7099
|
};
|
|
7285
7100
|
}
|
|
7286
|
-
return
|
|
7101
|
+
return (
|
|
7102
|
+
Object.freeze(this._document)
|
|
7103
|
+
);
|
|
7287
7104
|
}
|
|
7288
7105
|
_acceptLanguageId(newLanguageId) {
|
|
7289
7106
|
ok(!this._isDisposed);
|
|
@@ -8287,7 +8104,10 @@ let MainThreadQuickOpen = class MainThreadQuickOpen {
|
|
|
8287
8104
|
return Promise.resolve(undefined);
|
|
8288
8105
|
}
|
|
8289
8106
|
};
|
|
8290
|
-
MainThreadQuickOpen =
|
|
8107
|
+
MainThreadQuickOpen = __decorate([
|
|
8108
|
+
extHostNamedCustomer(MainContext.MainThreadQuickOpen),
|
|
8109
|
+
__param(1, IQuickInputService)
|
|
8110
|
+
], MainThreadQuickOpen);
|
|
8291
8111
|
function isMessageItem(item) {
|
|
8292
8112
|
return item && item.title;
|
|
8293
8113
|
}
|
|
@@ -8335,7 +8155,9 @@ let ExtHostMessageService = class ExtHostMessageService {
|
|
|
8335
8155
|
});
|
|
8336
8156
|
}
|
|
8337
8157
|
};
|
|
8338
|
-
ExtHostMessageService =
|
|
8158
|
+
ExtHostMessageService = __decorate([
|
|
8159
|
+
__param(1, ILogService)
|
|
8160
|
+
], ExtHostMessageService);
|
|
8339
8161
|
let MainThreadMessageService = class MainThreadMessageService {
|
|
8340
8162
|
constructor(extHostContext, _notificationService, _commandService, _dialogService) {
|
|
8341
8163
|
this._notificationService = _notificationService;
|
|
@@ -8427,14 +8249,12 @@ let MainThreadMessageService = class MainThreadMessageService {
|
|
|
8427
8249
|
return choice === commands.length ? undefined : commands[choice].handle;
|
|
8428
8250
|
}
|
|
8429
8251
|
};
|
|
8430
|
-
MainThreadMessageService =
|
|
8431
|
-
|
|
8432
|
-
|
|
8433
|
-
|
|
8434
|
-
|
|
8435
|
-
|
|
8436
|
-
});
|
|
8437
|
-
Object.freeze({ report() { } });
|
|
8252
|
+
MainThreadMessageService = __decorate([
|
|
8253
|
+
extHostNamedCustomer(MainContext.MainThreadMessageService),
|
|
8254
|
+
__param(1, INotificationService),
|
|
8255
|
+
__param(2, ICommandService),
|
|
8256
|
+
__param(3, IDialogService)
|
|
8257
|
+
], MainThreadMessageService);
|
|
8438
8258
|
class ExtHostProgress {
|
|
8439
8259
|
constructor(proxy) {
|
|
8440
8260
|
this._handles = 0;
|
|
@@ -8547,7 +8367,11 @@ let MainThreadProgress = class MainThreadProgress {
|
|
|
8547
8367
|
};
|
|
8548
8368
|
}
|
|
8549
8369
|
};
|
|
8550
|
-
MainThreadProgress =
|
|
8370
|
+
MainThreadProgress = __decorate([
|
|
8371
|
+
extHostNamedCustomer(MainContext.MainThreadProgress),
|
|
8372
|
+
__param(1, IProgressService),
|
|
8373
|
+
__param(2, ICommandService)
|
|
8374
|
+
], MainThreadProgress);
|
|
8551
8375
|
let MainThreadDocumentContentProviders = class MainThreadDocumentContentProviders {
|
|
8552
8376
|
constructor(extHostContext, _textModelResolverService, _languageService, _modelService, _editorWorkerService) {
|
|
8553
8377
|
this._textModelResolverService = _textModelResolverService;
|
|
@@ -8606,7 +8430,13 @@ let MainThreadDocumentContentProviders = class MainThreadDocumentContentProvider
|
|
|
8606
8430
|
}).catch(onUnexpectedError);
|
|
8607
8431
|
}
|
|
8608
8432
|
};
|
|
8609
|
-
MainThreadDocumentContentProviders =
|
|
8433
|
+
MainThreadDocumentContentProviders = __decorate([
|
|
8434
|
+
extHostNamedCustomer(MainContext.MainThreadDocumentContentProviders),
|
|
8435
|
+
__param(1, ITextModelService),
|
|
8436
|
+
__param(2, ILanguageService),
|
|
8437
|
+
__param(3, IModelService),
|
|
8438
|
+
__param(4, IEditorWorkerService)
|
|
8439
|
+
], MainThreadDocumentContentProviders);
|
|
8610
8440
|
class ExtHostDocumentContentProvider {
|
|
8611
8441
|
constructor(mainContext, _documentsAndEditors, _logService) {
|
|
8612
8442
|
this._documentsAndEditors = _documentsAndEditors;
|
|
@@ -8670,7 +8500,7 @@ class TextEditorDecorationType {
|
|
|
8670
8500
|
constructor(proxy, extension, options) {
|
|
8671
8501
|
const key = TextEditorDecorationType._Keys.nextId();
|
|
8672
8502
|
proxy.$registerTextEditorDecorationType(extension.identifier, key, DecorationRenderOptions.from(options));
|
|
8673
|
-
this.value =
|
|
8503
|
+
this.value = Object.freeze({
|
|
8674
8504
|
key,
|
|
8675
8505
|
dispose() {
|
|
8676
8506
|
proxy.$removeTextEditorDecorationType(key);
|
|
@@ -8921,7 +8751,7 @@ class ExtHostTextEditor {
|
|
|
8921
8751
|
this._visibleRanges = visibleRanges;
|
|
8922
8752
|
this._viewColumn = viewColumn;
|
|
8923
8753
|
const that = this;
|
|
8924
|
-
this.value =
|
|
8754
|
+
this.value = Object.freeze({
|
|
8925
8755
|
get document() {
|
|
8926
8756
|
return document.getValue();
|
|
8927
8757
|
},
|
|
@@ -9263,7 +9093,10 @@ let ExtHostDocumentsAndEditors = class ExtHostDocumentsAndEditors {
|
|
|
9263
9093
|
return [...this._editors.values()];
|
|
9264
9094
|
}
|
|
9265
9095
|
};
|
|
9266
|
-
ExtHostDocumentsAndEditors =
|
|
9096
|
+
ExtHostDocumentsAndEditors = __decorate([
|
|
9097
|
+
__param(0, IExtHostRpcService),
|
|
9098
|
+
__param(1, ILogService)
|
|
9099
|
+
], ExtHostDocumentsAndEditors);
|
|
9267
9100
|
class ExtHostEditors {
|
|
9268
9101
|
constructor(mainContext, _extHostDocumentsAndEditors) {
|
|
9269
9102
|
this._extHostDocumentsAndEditors = _extHostDocumentsAndEditors;
|
|
@@ -9602,7 +9435,16 @@ let MainThreadDocuments = class MainThreadDocuments extends Disposable$2 {
|
|
|
9602
9435
|
return resource;
|
|
9603
9436
|
}
|
|
9604
9437
|
};
|
|
9605
|
-
MainThreadDocuments =
|
|
9438
|
+
MainThreadDocuments = __decorate([
|
|
9439
|
+
__param(1, IModelService),
|
|
9440
|
+
__param(2, ITextFileService),
|
|
9441
|
+
__param(3, IFileService),
|
|
9442
|
+
__param(4, ITextModelService),
|
|
9443
|
+
__param(5, IWorkbenchEnvironmentService),
|
|
9444
|
+
__param(6, IUriIdentityService),
|
|
9445
|
+
__param(7, IWorkingCopyFileService),
|
|
9446
|
+
__param(8, IPathService)
|
|
9447
|
+
], MainThreadDocuments);
|
|
9606
9448
|
const Selection$1 = monaco.Selection;
|
|
9607
9449
|
class MainThreadTextEditorProperties {
|
|
9608
9450
|
constructor(selections, options, visibleRanges) {
|
|
@@ -9694,10 +9536,10 @@ class MainThreadTextEditorProperties {
|
|
|
9694
9536
|
return null;
|
|
9695
9537
|
}
|
|
9696
9538
|
static _selectionsEqual(a, b) {
|
|
9697
|
-
return equals
|
|
9539
|
+
return equals(a, b, (aValue, bValue) => aValue.equalsSelection(bValue));
|
|
9698
9540
|
}
|
|
9699
9541
|
static _rangesEqual(a, b) {
|
|
9700
|
-
return equals
|
|
9542
|
+
return equals(a, b, (aValue, bValue) => aValue.equalsRange(bValue));
|
|
9701
9543
|
}
|
|
9702
9544
|
static _optionsEqual(a, b) {
|
|
9703
9545
|
if (a && !b || !a && b) {
|
|
@@ -10012,6 +9854,7 @@ function editorGroupToColumn(editorGroupService, editorGroup) {
|
|
|
10012
9854
|
const group = (typeof editorGroup === 'number') ? editorGroupService.getGroup(editorGroup) : editorGroup;
|
|
10013
9855
|
return editorGroupService.getGroups(2 ).indexOf(group ?? editorGroupService.activeGroup);
|
|
10014
9856
|
}
|
|
9857
|
+
const INotebookEditorModelResolverService = createDecorator('INotebookModelResolverService');
|
|
10015
9858
|
class ResourceNotebookCellEdit extends ResourceEdit {
|
|
10016
9859
|
constructor(resource, cellEdit, versionId, metadata) {
|
|
10017
9860
|
super(metadata);
|
|
@@ -10020,6 +9863,36 @@ class ResourceNotebookCellEdit extends ResourceEdit {
|
|
|
10020
9863
|
this.versionId = versionId;
|
|
10021
9864
|
}
|
|
10022
9865
|
}
|
|
9866
|
+
let BulkCellEdits = class BulkCellEdits {
|
|
9867
|
+
constructor(_undoRedoGroup, undoRedoSource, _progress, _token, _edits, _notebookModelService) {
|
|
9868
|
+
this._undoRedoGroup = _undoRedoGroup;
|
|
9869
|
+
this._progress = _progress;
|
|
9870
|
+
this._token = _token;
|
|
9871
|
+
this._edits = _edits;
|
|
9872
|
+
this._notebookModelService = _notebookModelService;
|
|
9873
|
+
}
|
|
9874
|
+
async apply() {
|
|
9875
|
+
const editsByNotebook = groupBy(this._edits, (a, b) => compare(a.resource.toString(), b.resource.toString()));
|
|
9876
|
+
for (let group of editsByNotebook) {
|
|
9877
|
+
if (this._token.isCancellationRequested) {
|
|
9878
|
+
break;
|
|
9879
|
+
}
|
|
9880
|
+
const [first] = group;
|
|
9881
|
+
const ref = await this._notebookModelService.resolve(first.resource);
|
|
9882
|
+
if (typeof first.versionId === 'number' && ref.object.notebook.versionId !== first.versionId) {
|
|
9883
|
+
ref.dispose();
|
|
9884
|
+
throw new Error(`Notebook '${first.resource}' has changed in the meantime`);
|
|
9885
|
+
}
|
|
9886
|
+
const edits = group.map(entry => entry.cellEdit);
|
|
9887
|
+
ref.object.notebook.applyEdits(edits, true, undefined, () => undefined, this._undoRedoGroup);
|
|
9888
|
+
ref.dispose();
|
|
9889
|
+
this._progress.report(undefined);
|
|
9890
|
+
}
|
|
9891
|
+
}
|
|
9892
|
+
};
|
|
9893
|
+
BulkCellEdits = __decorate([
|
|
9894
|
+
__param(5, INotebookEditorModelResolverService)
|
|
9895
|
+
], BulkCellEdits);
|
|
10023
9896
|
var CellExecutionUpdateType;
|
|
10024
9897
|
(function(CellExecutionUpdateType) {
|
|
10025
9898
|
CellExecutionUpdateType[CellExecutionUpdateType["Output"] = 1] = "Output";
|
|
@@ -10215,7 +10088,7 @@ let MainThreadTextEditors = class MainThreadTextEditors {
|
|
|
10215
10088
|
}
|
|
10216
10089
|
_updateActiveAndVisibleTextEditors() {
|
|
10217
10090
|
const editorPositionData = this._getTextEditorPositionData();
|
|
10218
|
-
if (!equals$
|
|
10091
|
+
if (!equals$1(this._editorPositionData, editorPositionData)) {
|
|
10219
10092
|
this._editorPositionData = editorPositionData;
|
|
10220
10093
|
this._proxy.$acceptEditorPositionData(this._editorPositionData);
|
|
10221
10094
|
}
|
|
@@ -10365,950 +10238,78 @@ let MainThreadTextEditors = class MainThreadTextEditors {
|
|
|
10365
10238
|
}
|
|
10366
10239
|
};
|
|
10367
10240
|
MainThreadTextEditors.INSTANCE_COUNT = 0;
|
|
10368
|
-
MainThreadTextEditors =
|
|
10369
|
-
|
|
10370
|
-
|
|
10371
|
-
|
|
10372
|
-
|
|
10373
|
-
|
|
10374
|
-
|
|
10375
|
-
|
|
10376
|
-
|
|
10377
|
-
|
|
10378
|
-
|
|
10379
|
-
|
|
10380
|
-
|
|
10381
|
-
endColumn: options.selection.endColumn ?? options.selection.startColumn
|
|
10382
|
-
};
|
|
10383
|
-
editor.setSelection(range, options.selectionSource ?? "code.navigation" );
|
|
10384
|
-
if (options.selectionRevealType === 2 ) {
|
|
10385
|
-
editor.revealRangeNearTop(range, scrollType);
|
|
10386
|
-
}
|
|
10387
|
-
else if (options.selectionRevealType === 3 ) {
|
|
10388
|
-
editor.revealRangeNearTopIfOutsideViewport(range, scrollType);
|
|
10389
|
-
}
|
|
10390
|
-
else if (options.selectionRevealType === 1 ) {
|
|
10391
|
-
editor.revealRangeInCenterIfOutsideViewport(range, scrollType);
|
|
10392
|
-
}
|
|
10393
|
-
else {
|
|
10394
|
-
editor.revealRangeInCenter(range, scrollType);
|
|
10241
|
+
MainThreadTextEditors = __decorate([
|
|
10242
|
+
__param(2, ICodeEditorService),
|
|
10243
|
+
__param(3, IBulkEditService),
|
|
10244
|
+
__param(4, IEditorService),
|
|
10245
|
+
__param(5, IEditorGroupsService)
|
|
10246
|
+
], MainThreadTextEditors);
|
|
10247
|
+
class BaseTextEditor {}
|
|
10248
|
+
function diffSets(before, after) {
|
|
10249
|
+
const removed = [];
|
|
10250
|
+
const added = [];
|
|
10251
|
+
for (let element of before) {
|
|
10252
|
+
if (!after.has(element)) {
|
|
10253
|
+
removed.push(element);
|
|
10395
10254
|
}
|
|
10396
|
-
applied = true;
|
|
10397
|
-
}
|
|
10398
|
-
return applied;
|
|
10399
|
-
}
|
|
10400
|
-
function massageEditorViewState(options) {
|
|
10401
|
-
if (!options.selection || !options.viewState) {
|
|
10402
|
-
return options.viewState;
|
|
10403
|
-
}
|
|
10404
|
-
const candidateDiffViewState = options.viewState;
|
|
10405
|
-
if (candidateDiffViewState.modified) {
|
|
10406
|
-
candidateDiffViewState.modified.cursorState = [];
|
|
10407
|
-
return candidateDiffViewState;
|
|
10408
|
-
}
|
|
10409
|
-
const candidateEditorViewState = options.viewState;
|
|
10410
|
-
if (candidateEditorViewState.cursorState) {
|
|
10411
|
-
candidateEditorViewState.cursorState = [];
|
|
10412
|
-
}
|
|
10413
|
-
return candidateEditorViewState;
|
|
10414
|
-
}
|
|
10415
|
-
class EditorPaneRegistry {
|
|
10416
|
-
constructor() {
|
|
10417
|
-
this.editorPanes = [];
|
|
10418
|
-
this.mapEditorPanesToEditors = new Map();
|
|
10419
|
-
}
|
|
10420
|
-
registerEditorPane(editorPaneDescriptor, editorDescriptors) {
|
|
10421
|
-
this.mapEditorPanesToEditors.set(editorPaneDescriptor, editorDescriptors);
|
|
10422
|
-
const remove = insert(this.editorPanes, editorPaneDescriptor);
|
|
10423
|
-
return toDisposable(() => {
|
|
10424
|
-
this.mapEditorPanesToEditors.delete(editorPaneDescriptor);
|
|
10425
|
-
remove();
|
|
10426
|
-
});
|
|
10427
10255
|
}
|
|
10428
|
-
|
|
10429
|
-
|
|
10430
|
-
|
|
10431
|
-
return undefined;
|
|
10432
|
-
}
|
|
10433
|
-
if (descriptors.length === 1) {
|
|
10434
|
-
return descriptors[0];
|
|
10256
|
+
for (let element of after) {
|
|
10257
|
+
if (!before.has(element)) {
|
|
10258
|
+
added.push(element);
|
|
10435
10259
|
}
|
|
10436
|
-
return editor.prefersEditorPane(descriptors);
|
|
10437
10260
|
}
|
|
10438
|
-
|
|
10439
|
-
|
|
10440
|
-
|
|
10441
|
-
|
|
10442
|
-
|
|
10443
|
-
|
|
10444
|
-
|
|
10445
|
-
|
|
10446
|
-
break;
|
|
10447
|
-
}
|
|
10448
|
-
else if (byInstanceOf && editor instanceof editorClass) {
|
|
10449
|
-
matchingEditorPaneDescriptors.push(editorPane);
|
|
10450
|
-
break;
|
|
10451
|
-
}
|
|
10452
|
-
}
|
|
10453
|
-
}
|
|
10454
|
-
if (!byInstanceOf && matchingEditorPaneDescriptors.length === 0) {
|
|
10455
|
-
return this.findEditorPaneDescriptors(editor, true);
|
|
10261
|
+
return { removed, added };
|
|
10262
|
+
}
|
|
10263
|
+
function diffMaps(before, after) {
|
|
10264
|
+
const removed = [];
|
|
10265
|
+
const added = [];
|
|
10266
|
+
for (let [index, value] of before) {
|
|
10267
|
+
if (!after.has(index)) {
|
|
10268
|
+
removed.push(value);
|
|
10456
10269
|
}
|
|
10457
|
-
return matchingEditorPaneDescriptors;
|
|
10458
|
-
}
|
|
10459
|
-
getEditorPaneByType(typeId) {
|
|
10460
|
-
return this.editorPanes.find(editor => editor.typeId === typeId);
|
|
10461
|
-
}
|
|
10462
|
-
getEditorPanes() {
|
|
10463
|
-
return this.editorPanes.slice(0);
|
|
10464
10270
|
}
|
|
10465
|
-
|
|
10466
|
-
|
|
10467
|
-
|
|
10468
|
-
const editorDescriptors = this.mapEditorPanesToEditors.get(editorPane);
|
|
10469
|
-
if (editorDescriptors) {
|
|
10470
|
-
editorClasses.push(...editorDescriptors.map(editorDescriptor => editorDescriptor.ctor));
|
|
10471
|
-
}
|
|
10271
|
+
for (let [index, value] of after) {
|
|
10272
|
+
if (!before.has(index)) {
|
|
10273
|
+
added.push(value);
|
|
10472
10274
|
}
|
|
10473
|
-
return editorClasses;
|
|
10474
10275
|
}
|
|
10276
|
+
return { removed, added };
|
|
10475
10277
|
}
|
|
10476
|
-
|
|
10477
|
-
|
|
10478
|
-
|
|
10479
|
-
|
|
10480
|
-
ariaLabel = localize('preview', "{0}, preview", ariaLabel);
|
|
10278
|
+
class TextEditorSnapshot {
|
|
10279
|
+
constructor(editor) {
|
|
10280
|
+
this.editor = editor;
|
|
10281
|
+
this.id = `${editor.getId()},${editor.getModel().id}`;
|
|
10481
10282
|
}
|
|
10482
|
-
|
|
10483
|
-
|
|
10283
|
+
}
|
|
10284
|
+
class DocumentAndEditorStateDelta {
|
|
10285
|
+
constructor(removedDocuments, addedDocuments, removedEditors, addedEditors, oldActiveEditor, newActiveEditor) {
|
|
10286
|
+
this.removedDocuments = removedDocuments;
|
|
10287
|
+
this.addedDocuments = addedDocuments;
|
|
10288
|
+
this.removedEditors = removedEditors;
|
|
10289
|
+
this.addedEditors = addedEditors;
|
|
10290
|
+
this.oldActiveEditor = oldActiveEditor;
|
|
10291
|
+
this.newActiveEditor = newActiveEditor;
|
|
10292
|
+
this.isEmpty = this.removedDocuments.length === 0
|
|
10293
|
+
&& this.addedDocuments.length === 0
|
|
10294
|
+
&& this.removedEditors.length === 0
|
|
10295
|
+
&& this.addedEditors.length === 0
|
|
10296
|
+
&& oldActiveEditor === newActiveEditor;
|
|
10484
10297
|
}
|
|
10485
|
-
|
|
10486
|
-
|
|
10298
|
+
toString() {
|
|
10299
|
+
let ret = 'DocumentAndEditorStateDelta\n';
|
|
10300
|
+
ret += `\tRemoved Documents: [${this.removedDocuments.map(d => d.uri.toString(true)).join(', ')}]\n`;
|
|
10301
|
+
ret += `\tAdded Documents: [${this.addedDocuments.map(d => d.uri.toString(true)).join(', ')}]\n`;
|
|
10302
|
+
ret += `\tRemoved Editors: [${this.removedEditors.map(e => e.id).join(', ')}]\n`;
|
|
10303
|
+
ret += `\tAdded Editors: [${this.addedEditors.map(e => e.id).join(', ')}]\n`;
|
|
10304
|
+
ret += `\tNew Active Editor: ${this.newActiveEditor}\n`;
|
|
10305
|
+
return ret;
|
|
10487
10306
|
}
|
|
10488
|
-
return ariaLabel;
|
|
10489
10307
|
}
|
|
10490
|
-
class
|
|
10491
|
-
constructor(
|
|
10492
|
-
this.
|
|
10493
|
-
this.
|
|
10494
|
-
|
|
10495
|
-
getMemento(scope, target) {
|
|
10496
|
-
if (scope === 1 ) {
|
|
10497
|
-
let workspaceMemento = Memento.workspaceMementos.get(this.id);
|
|
10498
|
-
if (!workspaceMemento) {
|
|
10499
|
-
workspaceMemento = new ScopedMemento(this.id, scope, target, this.storageService);
|
|
10500
|
-
Memento.workspaceMementos.set(this.id, workspaceMemento);
|
|
10501
|
-
}
|
|
10502
|
-
return workspaceMemento.getMemento();
|
|
10503
|
-
}
|
|
10504
|
-
let globalMemento = Memento.globalMementos.get(this.id);
|
|
10505
|
-
if (!globalMemento) {
|
|
10506
|
-
globalMemento = new ScopedMemento(this.id, scope, target, this.storageService);
|
|
10507
|
-
Memento.globalMementos.set(this.id, globalMemento);
|
|
10508
|
-
}
|
|
10509
|
-
return globalMemento.getMemento();
|
|
10510
|
-
}
|
|
10511
|
-
saveMemento() {
|
|
10512
|
-
const workspaceMemento = Memento.workspaceMementos.get(this.id);
|
|
10513
|
-
if (workspaceMemento) {
|
|
10514
|
-
workspaceMemento.save();
|
|
10515
|
-
}
|
|
10516
|
-
const globalMemento = Memento.globalMementos.get(this.id);
|
|
10517
|
-
if (globalMemento) {
|
|
10518
|
-
globalMemento.save();
|
|
10519
|
-
}
|
|
10520
|
-
}
|
|
10521
|
-
static clear(scope) {
|
|
10522
|
-
if (scope === 1 ) {
|
|
10523
|
-
Memento.workspaceMementos.clear();
|
|
10524
|
-
}
|
|
10525
|
-
if (scope === 0 ) {
|
|
10526
|
-
Memento.globalMementos.clear();
|
|
10527
|
-
}
|
|
10528
|
-
}
|
|
10529
|
-
}
|
|
10530
|
-
Memento.globalMementos = new Map();
|
|
10531
|
-
Memento.workspaceMementos = new Map();
|
|
10532
|
-
Memento.COMMON_PREFIX = 'memento/';
|
|
10533
|
-
class ScopedMemento {
|
|
10534
|
-
constructor(id, scope, target, storageService) {
|
|
10535
|
-
this.id = id;
|
|
10536
|
-
this.scope = scope;
|
|
10537
|
-
this.target = target;
|
|
10538
|
-
this.storageService = storageService;
|
|
10539
|
-
this.mementoObj = this.load();
|
|
10540
|
-
}
|
|
10541
|
-
getMemento() {
|
|
10542
|
-
return this.mementoObj;
|
|
10543
|
-
}
|
|
10544
|
-
load() {
|
|
10545
|
-
const memento = this.storageService.get(this.id, this.scope);
|
|
10546
|
-
if (memento) {
|
|
10547
|
-
try {
|
|
10548
|
-
return JSON.parse(memento);
|
|
10549
|
-
}
|
|
10550
|
-
catch (error) {
|
|
10551
|
-
onUnexpectedError(`[memento]: failed to parse contents: ${error} (id: ${this.id}, scope: ${this.scope}, contents: ${memento})`);
|
|
10552
|
-
}
|
|
10553
|
-
}
|
|
10554
|
-
return {};
|
|
10555
|
-
}
|
|
10556
|
-
save() {
|
|
10557
|
-
if (!isEmptyObject(this.mementoObj)) {
|
|
10558
|
-
this.storageService.store(this.id, JSON.stringify(this.mementoObj), this.scope, this.target);
|
|
10559
|
-
}
|
|
10560
|
-
else {
|
|
10561
|
-
this.storageService.remove(this.id, this.scope);
|
|
10562
|
-
}
|
|
10563
|
-
}
|
|
10564
|
-
}
|
|
10565
|
-
class Component extends Themable {
|
|
10566
|
-
constructor(id, themeService, storageService) {
|
|
10567
|
-
super(themeService);
|
|
10568
|
-
this.id = id;
|
|
10569
|
-
this.id = id;
|
|
10570
|
-
this.memento = new Memento(this.id, storageService);
|
|
10571
|
-
this._register(storageService.onWillSaveState(() => {
|
|
10572
|
-
this.saveState();
|
|
10573
|
-
this.memento.saveMemento();
|
|
10574
|
-
}));
|
|
10575
|
-
}
|
|
10576
|
-
getId() {
|
|
10577
|
-
return this.id;
|
|
10578
|
-
}
|
|
10579
|
-
getMemento(scope, target) {
|
|
10580
|
-
return this.memento.getMemento(scope, target);
|
|
10581
|
-
}
|
|
10582
|
-
saveState() {
|
|
10583
|
-
}
|
|
10584
|
-
}
|
|
10585
|
-
class Composite extends Component {
|
|
10586
|
-
constructor(id, telemetryService, themeService, storageService) {
|
|
10587
|
-
super(id, themeService, storageService);
|
|
10588
|
-
this._onTitleAreaUpdate = this._register( new Emitter());
|
|
10589
|
-
this.onTitleAreaUpdate = this._onTitleAreaUpdate.event;
|
|
10590
|
-
this._hasFocus = false;
|
|
10591
|
-
this._telemetryService = telemetryService;
|
|
10592
|
-
this.visible = false;
|
|
10593
|
-
}
|
|
10594
|
-
get onDidFocus() {
|
|
10595
|
-
if (!this._onDidFocus) {
|
|
10596
|
-
this._onDidFocus = this.registerFocusTrackEvents().onDidFocus;
|
|
10597
|
-
}
|
|
10598
|
-
return this._onDidFocus.event;
|
|
10599
|
-
}
|
|
10600
|
-
fireOnDidFocus() {
|
|
10601
|
-
this._onDidFocus?.fire();
|
|
10602
|
-
}
|
|
10603
|
-
get onDidBlur() {
|
|
10604
|
-
if (!this._onDidBlur) {
|
|
10605
|
-
this._onDidBlur = this.registerFocusTrackEvents().onDidBlur;
|
|
10606
|
-
}
|
|
10607
|
-
return this._onDidBlur.event;
|
|
10608
|
-
}
|
|
10609
|
-
hasFocus() {
|
|
10610
|
-
return this._hasFocus;
|
|
10611
|
-
}
|
|
10612
|
-
registerFocusTrackEvents() {
|
|
10613
|
-
const container = assertIsDefined(this.getContainer());
|
|
10614
|
-
const focusTracker = this._register(trackFocus(container));
|
|
10615
|
-
const onDidFocus = this._onDidFocus = this._register( new Emitter());
|
|
10616
|
-
this._register(focusTracker.onDidFocus(() => {
|
|
10617
|
-
this._hasFocus = true;
|
|
10618
|
-
onDidFocus.fire();
|
|
10619
|
-
}));
|
|
10620
|
-
const onDidBlur = this._onDidBlur = this._register( new Emitter());
|
|
10621
|
-
this._register(focusTracker.onDidBlur(() => {
|
|
10622
|
-
this._hasFocus = false;
|
|
10623
|
-
onDidBlur.fire();
|
|
10624
|
-
}));
|
|
10625
|
-
return { onDidFocus, onDidBlur };
|
|
10626
|
-
}
|
|
10627
|
-
get telemetryService() { return this._telemetryService; }
|
|
10628
|
-
getTitle() {
|
|
10629
|
-
return undefined;
|
|
10630
|
-
}
|
|
10631
|
-
create(parent) {
|
|
10632
|
-
this.parent = parent;
|
|
10633
|
-
}
|
|
10634
|
-
getContainer() {
|
|
10635
|
-
return this.parent;
|
|
10636
|
-
}
|
|
10637
|
-
setVisible(visible) {
|
|
10638
|
-
if (this.visible !== !!visible) {
|
|
10639
|
-
this.visible = visible;
|
|
10640
|
-
}
|
|
10641
|
-
}
|
|
10642
|
-
focus() {
|
|
10643
|
-
}
|
|
10644
|
-
updateStyles() {
|
|
10645
|
-
super.updateStyles();
|
|
10646
|
-
}
|
|
10647
|
-
getActions() {
|
|
10648
|
-
return [];
|
|
10649
|
-
}
|
|
10650
|
-
getSecondaryActions() {
|
|
10651
|
-
return [];
|
|
10652
|
-
}
|
|
10653
|
-
getContextMenuActions() {
|
|
10654
|
-
return [];
|
|
10655
|
-
}
|
|
10656
|
-
getActionViewItem(action) {
|
|
10657
|
-
return undefined;
|
|
10658
|
-
}
|
|
10659
|
-
getActionsContext() {
|
|
10660
|
-
return null;
|
|
10661
|
-
}
|
|
10662
|
-
getActionRunner() {
|
|
10663
|
-
if (!this.actionRunner) {
|
|
10664
|
-
this.actionRunner = this._register( new ActionRunner());
|
|
10665
|
-
}
|
|
10666
|
-
return this.actionRunner;
|
|
10667
|
-
}
|
|
10668
|
-
updateTitleArea() {
|
|
10669
|
-
this._onTitleAreaUpdate.fire();
|
|
10670
|
-
}
|
|
10671
|
-
isVisible() {
|
|
10672
|
-
return this.visible;
|
|
10673
|
-
}
|
|
10674
|
-
getControl() {
|
|
10675
|
-
return undefined;
|
|
10676
|
-
}
|
|
10677
|
-
}
|
|
10678
|
-
const DEFAULT_EDITOR_MIN_DIMENSIONS = new Dimension(220, 70);
|
|
10679
|
-
const DEFAULT_EDITOR_MAX_DIMENSIONS = new Dimension(Number.POSITIVE_INFINITY, Number.POSITIVE_INFINITY);
|
|
10680
|
-
class EditorPane extends Composite {
|
|
10681
|
-
constructor(id, telemetryService, themeService, storageService) {
|
|
10682
|
-
super(id, telemetryService, themeService, storageService);
|
|
10683
|
-
this.onDidChangeSizeConstraints = Event.None;
|
|
10684
|
-
this._onDidChangeControl = this._register( new Emitter());
|
|
10685
|
-
this.onDidChangeControl = this._onDidChangeControl.event;
|
|
10686
|
-
}
|
|
10687
|
-
get minimumWidth() { return DEFAULT_EDITOR_MIN_DIMENSIONS.width; }
|
|
10688
|
-
get maximumWidth() { return DEFAULT_EDITOR_MAX_DIMENSIONS.width; }
|
|
10689
|
-
get minimumHeight() { return DEFAULT_EDITOR_MIN_DIMENSIONS.height; }
|
|
10690
|
-
get maximumHeight() { return DEFAULT_EDITOR_MAX_DIMENSIONS.height; }
|
|
10691
|
-
get input() { return this._input; }
|
|
10692
|
-
get options() { return this._options; }
|
|
10693
|
-
get group() { return this._group; }
|
|
10694
|
-
get scopedContextKeyService() { return undefined; }
|
|
10695
|
-
create(parent) {
|
|
10696
|
-
super.create(parent);
|
|
10697
|
-
this.createEditor(parent);
|
|
10698
|
-
}
|
|
10699
|
-
async setInput(input, options, context, token) {
|
|
10700
|
-
this._input = input;
|
|
10701
|
-
this._options = options;
|
|
10702
|
-
}
|
|
10703
|
-
clearInput() {
|
|
10704
|
-
this._input = undefined;
|
|
10705
|
-
this._options = undefined;
|
|
10706
|
-
}
|
|
10707
|
-
setOptions(options) {
|
|
10708
|
-
this._options = options;
|
|
10709
|
-
}
|
|
10710
|
-
setVisible(visible, group) {
|
|
10711
|
-
super.setVisible(visible);
|
|
10712
|
-
this.setEditorVisible(visible, group);
|
|
10713
|
-
}
|
|
10714
|
-
setEditorVisible(visible, group) {
|
|
10715
|
-
this._group = group;
|
|
10716
|
-
}
|
|
10717
|
-
getEditorMemento(editorGroupService, configurationService, key, limit = 10) {
|
|
10718
|
-
const mementoKey = `${this.getId()}${key}`;
|
|
10719
|
-
let editorMemento = EditorPane.EDITOR_MEMENTOS.get(mementoKey);
|
|
10720
|
-
if (!editorMemento) {
|
|
10721
|
-
editorMemento = this._register( new EditorMemento(
|
|
10722
|
-
this.getId(),
|
|
10723
|
-
key,
|
|
10724
|
-
this.getMemento(1 , 1 ),
|
|
10725
|
-
limit,
|
|
10726
|
-
editorGroupService,
|
|
10727
|
-
configurationService
|
|
10728
|
-
));
|
|
10729
|
-
EditorPane.EDITOR_MEMENTOS.set(mementoKey, editorMemento);
|
|
10730
|
-
}
|
|
10731
|
-
return editorMemento;
|
|
10732
|
-
}
|
|
10733
|
-
getViewState() {
|
|
10734
|
-
return undefined;
|
|
10735
|
-
}
|
|
10736
|
-
saveState() {
|
|
10737
|
-
for (const [, editorMemento] of EditorPane.EDITOR_MEMENTOS) {
|
|
10738
|
-
if (editorMemento.id === this.getId()) {
|
|
10739
|
-
editorMemento.saveState();
|
|
10740
|
-
}
|
|
10741
|
-
}
|
|
10742
|
-
super.saveState();
|
|
10743
|
-
}
|
|
10744
|
-
dispose() {
|
|
10745
|
-
this._input = undefined;
|
|
10746
|
-
this._options = undefined;
|
|
10747
|
-
super.dispose();
|
|
10748
|
-
}
|
|
10749
|
-
}
|
|
10750
|
-
EditorPane.EDITOR_MEMENTOS = new Map();
|
|
10751
|
-
class EditorMemento extends Disposable$2 {
|
|
10752
|
-
constructor(id, key, memento, limit, editorGroupService, configurationService) {
|
|
10753
|
-
super();
|
|
10754
|
-
this.id = id;
|
|
10755
|
-
this.key = key;
|
|
10756
|
-
this.memento = memento;
|
|
10757
|
-
this.limit = limit;
|
|
10758
|
-
this.editorGroupService = editorGroupService;
|
|
10759
|
-
this.configurationService = configurationService;
|
|
10760
|
-
this.cleanedUp = false;
|
|
10761
|
-
this.shareEditorState = false;
|
|
10762
|
-
this.updateConfiguration();
|
|
10763
|
-
this.registerListeners();
|
|
10764
|
-
}
|
|
10765
|
-
registerListeners() {
|
|
10766
|
-
this._register(this.configurationService.onDidChangeConfiguration(() => this.updateConfiguration()));
|
|
10767
|
-
}
|
|
10768
|
-
updateConfiguration() {
|
|
10769
|
-
this.shareEditorState = this.configurationService.getValue(undefined, 'workbench.editor.sharedViewState') === true;
|
|
10770
|
-
}
|
|
10771
|
-
saveEditorState(group, resourceOrEditor, state) {
|
|
10772
|
-
const resource = this.doGetResource(resourceOrEditor);
|
|
10773
|
-
if (!resource || !group) {
|
|
10774
|
-
return;
|
|
10775
|
-
}
|
|
10776
|
-
const cache = this.doLoad();
|
|
10777
|
-
let mementosForResource = cache.get(resource.toString());
|
|
10778
|
-
if (!mementosForResource) {
|
|
10779
|
-
mementosForResource = Object.create(null);
|
|
10780
|
-
cache.set(resource.toString(), mementosForResource);
|
|
10781
|
-
}
|
|
10782
|
-
mementosForResource[group.id] = state;
|
|
10783
|
-
if (this.shareEditorState) {
|
|
10784
|
-
mementosForResource[EditorMemento.SHARED_EDITOR_STATE] = state;
|
|
10785
|
-
}
|
|
10786
|
-
if (isEditorInput(resourceOrEditor)) {
|
|
10787
|
-
this.clearEditorStateOnDispose(resource, resourceOrEditor);
|
|
10788
|
-
}
|
|
10789
|
-
}
|
|
10790
|
-
loadEditorState(group, resourceOrEditor) {
|
|
10791
|
-
const resource = this.doGetResource(resourceOrEditor);
|
|
10792
|
-
if (!resource || !group) {
|
|
10793
|
-
return;
|
|
10794
|
-
}
|
|
10795
|
-
const cache = this.doLoad();
|
|
10796
|
-
const mementosForResource = cache.get(resource.toString());
|
|
10797
|
-
if (mementosForResource) {
|
|
10798
|
-
let mementoForResourceAndGroup = mementosForResource[group.id];
|
|
10799
|
-
if (mementoForResourceAndGroup) {
|
|
10800
|
-
return mementoForResourceAndGroup;
|
|
10801
|
-
}
|
|
10802
|
-
if (this.shareEditorState) {
|
|
10803
|
-
return mementosForResource[EditorMemento.SHARED_EDITOR_STATE];
|
|
10804
|
-
}
|
|
10805
|
-
}
|
|
10806
|
-
return undefined;
|
|
10807
|
-
}
|
|
10808
|
-
clearEditorState(resourceOrEditor, group) {
|
|
10809
|
-
if (isEditorInput(resourceOrEditor)) {
|
|
10810
|
-
this.editorDisposables?.delete(resourceOrEditor);
|
|
10811
|
-
}
|
|
10812
|
-
const resource = this.doGetResource(resourceOrEditor);
|
|
10813
|
-
if (resource) {
|
|
10814
|
-
const cache = this.doLoad();
|
|
10815
|
-
if (group) {
|
|
10816
|
-
const mementosForResource = cache.get(resource.toString());
|
|
10817
|
-
if (mementosForResource) {
|
|
10818
|
-
delete mementosForResource[group.id];
|
|
10819
|
-
if (isEmptyObject(mementosForResource)) {
|
|
10820
|
-
cache.delete(resource.toString());
|
|
10821
|
-
}
|
|
10822
|
-
}
|
|
10823
|
-
}
|
|
10824
|
-
else {
|
|
10825
|
-
cache.delete(resource.toString());
|
|
10826
|
-
}
|
|
10827
|
-
}
|
|
10828
|
-
}
|
|
10829
|
-
clearEditorStateOnDispose(resource, editor) {
|
|
10830
|
-
if (!this.editorDisposables) {
|
|
10831
|
-
this.editorDisposables = new Map();
|
|
10832
|
-
}
|
|
10833
|
-
if (!this.editorDisposables.has(editor)) {
|
|
10834
|
-
this.editorDisposables.set(editor, Event.once(editor.onWillDispose)(() => {
|
|
10835
|
-
this.clearEditorState(resource);
|
|
10836
|
-
this.editorDisposables?.delete(editor);
|
|
10837
|
-
}));
|
|
10838
|
-
}
|
|
10839
|
-
}
|
|
10840
|
-
moveEditorState(source, target, comparer) {
|
|
10841
|
-
const cache = this.doLoad();
|
|
10842
|
-
const cacheKeys = [...cache.keys()];
|
|
10843
|
-
for (const cacheKey of cacheKeys) {
|
|
10844
|
-
const resource = URI.parse(cacheKey);
|
|
10845
|
-
if (!comparer.isEqualOrParent(resource, source)) {
|
|
10846
|
-
continue;
|
|
10847
|
-
}
|
|
10848
|
-
let targetResource;
|
|
10849
|
-
if (isEqual(source, resource)) {
|
|
10850
|
-
targetResource = target;
|
|
10851
|
-
}
|
|
10852
|
-
else {
|
|
10853
|
-
const index = indexOfPath(resource.path, source.path);
|
|
10854
|
-
targetResource = joinPath(target, resource.path.substr(index + source.path.length + 1));
|
|
10855
|
-
}
|
|
10856
|
-
const value = cache.get(cacheKey, 0 );
|
|
10857
|
-
if (value) {
|
|
10858
|
-
cache.delete(cacheKey);
|
|
10859
|
-
cache.set(targetResource.toString(), value);
|
|
10860
|
-
}
|
|
10861
|
-
}
|
|
10862
|
-
}
|
|
10863
|
-
doGetResource(resourceOrEditor) {
|
|
10864
|
-
if (isEditorInput(resourceOrEditor)) {
|
|
10865
|
-
return resourceOrEditor.resource;
|
|
10866
|
-
}
|
|
10867
|
-
return resourceOrEditor;
|
|
10868
|
-
}
|
|
10869
|
-
doLoad() {
|
|
10870
|
-
if (!this.cache) {
|
|
10871
|
-
this.cache = new LRUCache(this.limit);
|
|
10872
|
-
const rawEditorMemento = this.memento[this.key];
|
|
10873
|
-
if (Array.isArray(rawEditorMemento)) {
|
|
10874
|
-
this.cache.fromJSON(rawEditorMemento);
|
|
10875
|
-
}
|
|
10876
|
-
}
|
|
10877
|
-
return this.cache;
|
|
10878
|
-
}
|
|
10879
|
-
saveState() {
|
|
10880
|
-
const cache = this.doLoad();
|
|
10881
|
-
if (!this.cleanedUp) {
|
|
10882
|
-
this.cleanUp();
|
|
10883
|
-
this.cleanedUp = true;
|
|
10884
|
-
}
|
|
10885
|
-
this.memento[this.key] = cache.toJSON();
|
|
10886
|
-
}
|
|
10887
|
-
cleanUp() {
|
|
10888
|
-
const cache = this.doLoad();
|
|
10889
|
-
const entries = [...cache.entries()];
|
|
10890
|
-
for (const [resource, mapGroupToMementos] of entries) {
|
|
10891
|
-
for (const group of Object.keys(mapGroupToMementos)) {
|
|
10892
|
-
const groupId = Number(group);
|
|
10893
|
-
if (groupId === EditorMemento.SHARED_EDITOR_STATE && this.shareEditorState) {
|
|
10894
|
-
continue;
|
|
10895
|
-
}
|
|
10896
|
-
if (!this.editorGroupService.getGroup(groupId)) {
|
|
10897
|
-
delete mapGroupToMementos[groupId];
|
|
10898
|
-
if (isEmptyObject(mapGroupToMementos)) {
|
|
10899
|
-
cache.delete(resource);
|
|
10900
|
-
}
|
|
10901
|
-
}
|
|
10902
|
-
}
|
|
10903
|
-
}
|
|
10904
|
-
}
|
|
10905
|
-
}
|
|
10906
|
-
EditorMemento.SHARED_EDITOR_STATE = -1;
|
|
10907
|
-
const TELEMETRY_SETTING_ID = 'telemetry.telemetryLevel';
|
|
10908
|
-
const TELEMETRY_OLD_SETTING_ID = 'telemetry.enableTelemetry';
|
|
10909
|
-
let AbstractEditorWithViewState = class AbstractEditorWithViewState extends EditorPane {
|
|
10910
|
-
constructor(id, viewStateStorageKey, telemetryService, instantiationService, storageService, textResourceConfigurationService, themeService, editorService, editorGroupService) {
|
|
10911
|
-
super(id, telemetryService, themeService, storageService);
|
|
10912
|
-
this.instantiationService = instantiationService;
|
|
10913
|
-
this.textResourceConfigurationService = textResourceConfigurationService;
|
|
10914
|
-
this.editorService = editorService;
|
|
10915
|
-
this.editorGroupService = editorGroupService;
|
|
10916
|
-
this.groupListener = this._register( new MutableDisposable());
|
|
10917
|
-
this.viewState = this.getEditorMemento(editorGroupService, textResourceConfigurationService, viewStateStorageKey, 100);
|
|
10918
|
-
}
|
|
10919
|
-
setEditorVisible(visible, group) {
|
|
10920
|
-
this.groupListener.value = group?.onWillCloseEditor(e => this.onWillCloseEditor(e));
|
|
10921
|
-
super.setEditorVisible(visible, group);
|
|
10922
|
-
}
|
|
10923
|
-
onWillCloseEditor(e) {
|
|
10924
|
-
const editor = e.editor;
|
|
10925
|
-
if (editor === this.input) {
|
|
10926
|
-
this.updateEditorViewState(editor);
|
|
10927
|
-
}
|
|
10928
|
-
}
|
|
10929
|
-
clearInput() {
|
|
10930
|
-
this.updateEditorViewState(this.input);
|
|
10931
|
-
super.clearInput();
|
|
10932
|
-
}
|
|
10933
|
-
saveState() {
|
|
10934
|
-
this.updateEditorViewState(this.input);
|
|
10935
|
-
super.saveState();
|
|
10936
|
-
}
|
|
10937
|
-
updateEditorViewState(input) {
|
|
10938
|
-
if (!input || !this.tracksEditorViewState(input)) {
|
|
10939
|
-
return;
|
|
10940
|
-
}
|
|
10941
|
-
const resource = this.toEditorViewStateResource(input);
|
|
10942
|
-
if (!resource) {
|
|
10943
|
-
return;
|
|
10944
|
-
}
|
|
10945
|
-
if (!this.tracksDisposedEditorViewState()) {
|
|
10946
|
-
if (!this.editorViewStateDisposables) {
|
|
10947
|
-
this.editorViewStateDisposables = new Map();
|
|
10948
|
-
}
|
|
10949
|
-
if (!this.editorViewStateDisposables.has(input)) {
|
|
10950
|
-
this.editorViewStateDisposables.set(input, Event.once(input.onWillDispose)(() => {
|
|
10951
|
-
this.clearEditorViewState(resource, this.group);
|
|
10952
|
-
this.editorViewStateDisposables?.delete(input);
|
|
10953
|
-
}));
|
|
10954
|
-
}
|
|
10955
|
-
}
|
|
10956
|
-
if ((input.isDisposed() && !this.tracksDisposedEditorViewState()) ||
|
|
10957
|
-
(!this.shouldRestoreEditorViewState(input) && (!this.group || !this.group.contains(input)))) {
|
|
10958
|
-
this.clearEditorViewState(resource, this.group);
|
|
10959
|
-
}
|
|
10960
|
-
else if (!input.isDisposed()) {
|
|
10961
|
-
this.saveEditorViewState(resource);
|
|
10962
|
-
}
|
|
10963
|
-
}
|
|
10964
|
-
shouldRestoreEditorViewState(input, context) {
|
|
10965
|
-
if (context?.newInGroup) {
|
|
10966
|
-
return this.textResourceConfigurationService.getValue(EditorResourceAccessor.getOriginalUri(input, { supportSideBySide: SideBySideEditor.PRIMARY }), 'workbench.editor.restoreViewState') === false ? false : true ;
|
|
10967
|
-
}
|
|
10968
|
-
return true;
|
|
10969
|
-
}
|
|
10970
|
-
getViewState() {
|
|
10971
|
-
const input = this.input;
|
|
10972
|
-
if (!input || !this.tracksEditorViewState(input)) {
|
|
10973
|
-
return;
|
|
10974
|
-
}
|
|
10975
|
-
const resource = this.toEditorViewStateResource(input);
|
|
10976
|
-
if (!resource) {
|
|
10977
|
-
return;
|
|
10978
|
-
}
|
|
10979
|
-
return this.computeEditorViewState(resource);
|
|
10980
|
-
}
|
|
10981
|
-
saveEditorViewState(resource) {
|
|
10982
|
-
if (!this.group) {
|
|
10983
|
-
return;
|
|
10984
|
-
}
|
|
10985
|
-
const editorViewState = this.computeEditorViewState(resource);
|
|
10986
|
-
if (!editorViewState) {
|
|
10987
|
-
return;
|
|
10988
|
-
}
|
|
10989
|
-
this.viewState.saveEditorState(this.group, resource, editorViewState);
|
|
10990
|
-
}
|
|
10991
|
-
loadEditorViewState(input, context) {
|
|
10992
|
-
if (!input || !this.group) {
|
|
10993
|
-
return undefined;
|
|
10994
|
-
}
|
|
10995
|
-
if (!this.tracksEditorViewState(input)) {
|
|
10996
|
-
return undefined;
|
|
10997
|
-
}
|
|
10998
|
-
if (!this.shouldRestoreEditorViewState(input, context)) {
|
|
10999
|
-
return undefined;
|
|
11000
|
-
}
|
|
11001
|
-
const resource = this.toEditorViewStateResource(input);
|
|
11002
|
-
if (!resource) {
|
|
11003
|
-
return;
|
|
11004
|
-
}
|
|
11005
|
-
return this.viewState.loadEditorState(this.group, resource);
|
|
11006
|
-
}
|
|
11007
|
-
moveEditorViewState(source, target, comparer) {
|
|
11008
|
-
return this.viewState.moveEditorState(source, target, comparer);
|
|
11009
|
-
}
|
|
11010
|
-
clearEditorViewState(resource, group) {
|
|
11011
|
-
this.viewState.clearEditorState(resource, group);
|
|
11012
|
-
}
|
|
11013
|
-
dispose() {
|
|
11014
|
-
super.dispose();
|
|
11015
|
-
if (this.editorViewStateDisposables) {
|
|
11016
|
-
for (const [, disposables] of this.editorViewStateDisposables) {
|
|
11017
|
-
disposables.dispose();
|
|
11018
|
-
}
|
|
11019
|
-
this.editorViewStateDisposables = undefined;
|
|
11020
|
-
}
|
|
11021
|
-
}
|
|
11022
|
-
tracksDisposedEditorViewState() {
|
|
11023
|
-
return false;
|
|
11024
|
-
}
|
|
11025
|
-
};
|
|
11026
|
-
AbstractEditorWithViewState = AbstractEditorWithViewState;
|
|
11027
|
-
let BaseTextEditor = class BaseTextEditor extends AbstractEditorWithViewState {
|
|
11028
|
-
constructor(id, telemetryService, instantiationService, storageService, textResourceConfigurationService, themeService, editorService, editorGroupService) {
|
|
11029
|
-
super(id, BaseTextEditor.VIEW_STATE_PREFERENCE_KEY, telemetryService, instantiationService, storageService, textResourceConfigurationService, themeService, editorService, editorGroupService);
|
|
11030
|
-
this._onDidChangeSelection = this._register( new Emitter());
|
|
11031
|
-
this.onDidChangeSelection = this._onDidChangeSelection.event;
|
|
11032
|
-
this._register(this.textResourceConfigurationService.onDidChangeConfiguration(() => {
|
|
11033
|
-
const resource = this.getActiveResource();
|
|
11034
|
-
const value = resource ? this.textResourceConfigurationService.getValue(resource) : undefined;
|
|
11035
|
-
return this.handleConfigurationChangeEvent(value);
|
|
11036
|
-
}));
|
|
11037
|
-
this._register(Event.any(this.editorGroupService.onDidAddGroup, this.editorGroupService.onDidRemoveGroup)(() => {
|
|
11038
|
-
const ariaLabel = this.computeAriaLabel();
|
|
11039
|
-
this.editorContainer?.setAttribute('aria-label', ariaLabel);
|
|
11040
|
-
this.editorControl?.updateOptions({ ariaLabel });
|
|
11041
|
-
}));
|
|
11042
|
-
}
|
|
11043
|
-
get scopedContextKeyService() {
|
|
11044
|
-
return isCodeEditor(this.editorControl) ? this.editorControl.invokeWithinContext(accessor => accessor.get(IContextKeyService)) : undefined;
|
|
11045
|
-
}
|
|
11046
|
-
handleConfigurationChangeEvent(configuration) {
|
|
11047
|
-
if (this.isVisible()) {
|
|
11048
|
-
this.updateEditorConfiguration(configuration);
|
|
11049
|
-
}
|
|
11050
|
-
else {
|
|
11051
|
-
this.hasPendingConfigurationChange = true;
|
|
11052
|
-
}
|
|
11053
|
-
}
|
|
11054
|
-
consumePendingConfigurationChangeEvent() {
|
|
11055
|
-
if (this.hasPendingConfigurationChange) {
|
|
11056
|
-
this.updateEditorConfiguration();
|
|
11057
|
-
this.hasPendingConfigurationChange = false;
|
|
11058
|
-
}
|
|
11059
|
-
}
|
|
11060
|
-
computeConfiguration(configuration) {
|
|
11061
|
-
const editorConfiguration = isObject$1(configuration.editor) ? deepClone(configuration.editor) : Object.create(null);
|
|
11062
|
-
Object.assign(editorConfiguration, this.getConfigurationOverrides());
|
|
11063
|
-
editorConfiguration.ariaLabel = this.computeAriaLabel();
|
|
11064
|
-
return editorConfiguration;
|
|
11065
|
-
}
|
|
11066
|
-
computeAriaLabel() {
|
|
11067
|
-
return this._input ? computeEditorAriaLabel(this._input, undefined, this.group, this.editorGroupService.count) : localize('editor', "Editor");
|
|
11068
|
-
}
|
|
11069
|
-
getConfigurationOverrides() {
|
|
11070
|
-
return {
|
|
11071
|
-
overviewRulerLanes: 3,
|
|
11072
|
-
lineNumbersMinChars: 3,
|
|
11073
|
-
fixedOverflowWidgets: true,
|
|
11074
|
-
readOnly: this.input?.hasCapability(2 ),
|
|
11075
|
-
renderValidationDecorations: 'on'
|
|
11076
|
-
};
|
|
11077
|
-
}
|
|
11078
|
-
createEditor(parent) {
|
|
11079
|
-
this.editorContainer = parent;
|
|
11080
|
-
this.editorControl = this._register(this.createEditorControl(parent, this.computeConfiguration(this.textResourceConfigurationService.getValue(this.getActiveResource()))));
|
|
11081
|
-
this.registerCodeEditorListeners();
|
|
11082
|
-
}
|
|
11083
|
-
registerCodeEditorListeners() {
|
|
11084
|
-
const codeEditor = getCodeEditor(this.editorControl);
|
|
11085
|
-
if (codeEditor) {
|
|
11086
|
-
this._register(codeEditor.onDidChangeModelLanguage(() => this.updateEditorConfiguration()));
|
|
11087
|
-
this._register(codeEditor.onDidChangeModel(() => this.updateEditorConfiguration()));
|
|
11088
|
-
this._register(codeEditor.onDidChangeCursorPosition(e => this._onDidChangeSelection.fire({ reason: this.toEditorPaneSelectionChangeReason(e) })));
|
|
11089
|
-
this._register(codeEditor.onDidChangeModelContent(() => this._onDidChangeSelection.fire({ reason: 3 })));
|
|
11090
|
-
}
|
|
11091
|
-
}
|
|
11092
|
-
toEditorPaneSelectionChangeReason(e) {
|
|
11093
|
-
switch (e.source) {
|
|
11094
|
-
case "api" : return 1 ;
|
|
11095
|
-
case "code.navigation" : return 4 ;
|
|
11096
|
-
case "code.jump" : return 5 ;
|
|
11097
|
-
default: return 2 ;
|
|
11098
|
-
}
|
|
11099
|
-
}
|
|
11100
|
-
getSelection() {
|
|
11101
|
-
const codeEditor = getCodeEditor(this.editorControl);
|
|
11102
|
-
if (codeEditor) {
|
|
11103
|
-
const selection = codeEditor.getSelection();
|
|
11104
|
-
if (selection) {
|
|
11105
|
-
return (
|
|
11106
|
-
new TextEditorPaneSelection(selection)
|
|
11107
|
-
);
|
|
11108
|
-
}
|
|
11109
|
-
}
|
|
11110
|
-
return undefined;
|
|
11111
|
-
}
|
|
11112
|
-
createEditorControl(parent, configuration) {
|
|
11113
|
-
return this.instantiationService.createInstance(CodeEditorWidget, parent, configuration, {});
|
|
11114
|
-
}
|
|
11115
|
-
async setInput(input, options, context, token) {
|
|
11116
|
-
await super.setInput(input, options, context, token);
|
|
11117
|
-
this.updateEditorConfiguration();
|
|
11118
|
-
const editorContainer = assertIsDefined(this.editorContainer);
|
|
11119
|
-
editorContainer.setAttribute('aria-label', this.computeAriaLabel());
|
|
11120
|
-
}
|
|
11121
|
-
setOptions(options) {
|
|
11122
|
-
super.setOptions(options);
|
|
11123
|
-
if (options) {
|
|
11124
|
-
applyTextEditorOptions(options, assertIsDefined(this.getControl()), 0 );
|
|
11125
|
-
}
|
|
11126
|
-
}
|
|
11127
|
-
setEditorVisible(visible, group) {
|
|
11128
|
-
const editorControl = assertIsDefined(this.editorControl);
|
|
11129
|
-
if (visible) {
|
|
11130
|
-
this.consumePendingConfigurationChangeEvent();
|
|
11131
|
-
editorControl.onVisible();
|
|
11132
|
-
}
|
|
11133
|
-
else {
|
|
11134
|
-
editorControl.onHide();
|
|
11135
|
-
}
|
|
11136
|
-
super.setEditorVisible(visible, group);
|
|
11137
|
-
}
|
|
11138
|
-
focus() {
|
|
11139
|
-
const editorControl = assertIsDefined(this.editorControl);
|
|
11140
|
-
editorControl.focus();
|
|
11141
|
-
}
|
|
11142
|
-
hasFocus() {
|
|
11143
|
-
if (this.editorControl?.hasTextFocus()) {
|
|
11144
|
-
return true;
|
|
11145
|
-
}
|
|
11146
|
-
return super.hasFocus();
|
|
11147
|
-
}
|
|
11148
|
-
layout(dimension) {
|
|
11149
|
-
const editorControl = assertIsDefined(this.editorControl);
|
|
11150
|
-
editorControl.layout(dimension);
|
|
11151
|
-
}
|
|
11152
|
-
getControl() {
|
|
11153
|
-
return this.editorControl;
|
|
11154
|
-
}
|
|
11155
|
-
toEditorViewStateResource(input) {
|
|
11156
|
-
return input.resource;
|
|
11157
|
-
}
|
|
11158
|
-
computeEditorViewState(resource) {
|
|
11159
|
-
const control = this.getControl();
|
|
11160
|
-
if (!isCodeEditor(control)) {
|
|
11161
|
-
return undefined;
|
|
11162
|
-
}
|
|
11163
|
-
const model = control.getModel();
|
|
11164
|
-
if (!model) {
|
|
11165
|
-
return undefined;
|
|
11166
|
-
}
|
|
11167
|
-
const modelUri = model.uri;
|
|
11168
|
-
if (!modelUri) {
|
|
11169
|
-
return undefined;
|
|
11170
|
-
}
|
|
11171
|
-
if (!isEqual(modelUri, resource)) {
|
|
11172
|
-
return undefined;
|
|
11173
|
-
}
|
|
11174
|
-
return withNullAsUndefined(control.saveViewState());
|
|
11175
|
-
}
|
|
11176
|
-
updateEditorConfiguration(configuration) {
|
|
11177
|
-
if (!configuration) {
|
|
11178
|
-
const resource = this.getActiveResource();
|
|
11179
|
-
if (resource) {
|
|
11180
|
-
configuration = this.textResourceConfigurationService.getValue(resource);
|
|
11181
|
-
}
|
|
11182
|
-
}
|
|
11183
|
-
if (!this.editorControl || !configuration) {
|
|
11184
|
-
return;
|
|
11185
|
-
}
|
|
11186
|
-
const editorConfiguration = this.computeConfiguration(configuration);
|
|
11187
|
-
let editorSettingsToApply = editorConfiguration;
|
|
11188
|
-
if (this.lastAppliedEditorOptions) {
|
|
11189
|
-
editorSettingsToApply = distinct(this.lastAppliedEditorOptions, editorSettingsToApply);
|
|
11190
|
-
}
|
|
11191
|
-
if (Object.keys(editorSettingsToApply).length > 0) {
|
|
11192
|
-
this.lastAppliedEditorOptions = editorConfiguration;
|
|
11193
|
-
this.editorControl.updateOptions(editorSettingsToApply);
|
|
11194
|
-
}
|
|
11195
|
-
}
|
|
11196
|
-
getActiveResource() {
|
|
11197
|
-
const codeEditor = getCodeEditor(this.editorControl);
|
|
11198
|
-
if (codeEditor) {
|
|
11199
|
-
const model = codeEditor.getModel();
|
|
11200
|
-
if (model) {
|
|
11201
|
-
return model.uri;
|
|
11202
|
-
}
|
|
11203
|
-
}
|
|
11204
|
-
if (this.input) {
|
|
11205
|
-
return this.input.resource;
|
|
11206
|
-
}
|
|
11207
|
-
return undefined;
|
|
11208
|
-
}
|
|
11209
|
-
dispose() {
|
|
11210
|
-
this.lastAppliedEditorOptions = undefined;
|
|
11211
|
-
super.dispose();
|
|
11212
|
-
}
|
|
11213
|
-
};
|
|
11214
|
-
BaseTextEditor.VIEW_STATE_PREFERENCE_KEY = 'textEditorViewState';
|
|
11215
|
-
BaseTextEditor = BaseTextEditor;
|
|
11216
|
-
class TextEditorPaneSelection {
|
|
11217
|
-
constructor(textSelection) {
|
|
11218
|
-
this.textSelection = textSelection;
|
|
11219
|
-
}
|
|
11220
|
-
compare(other) {
|
|
11221
|
-
if (!(other instanceof TextEditorPaneSelection)) {
|
|
11222
|
-
return 3 ;
|
|
11223
|
-
}
|
|
11224
|
-
const thisLineNumber = Math.min(this.textSelection.selectionStartLineNumber, this.textSelection.positionLineNumber);
|
|
11225
|
-
const otherLineNumber = Math.min(other.textSelection.selectionStartLineNumber, other.textSelection.positionLineNumber);
|
|
11226
|
-
if (thisLineNumber === otherLineNumber) {
|
|
11227
|
-
return 1 ;
|
|
11228
|
-
}
|
|
11229
|
-
if (Math.abs(thisLineNumber - otherLineNumber) < TextEditorPaneSelection.TEXT_EDITOR_SELECTION_THRESHOLD) {
|
|
11230
|
-
return 2 ;
|
|
11231
|
-
}
|
|
11232
|
-
return 3 ;
|
|
11233
|
-
}
|
|
11234
|
-
restore(options) {
|
|
11235
|
-
const textEditorOptions = {
|
|
11236
|
-
...options,
|
|
11237
|
-
selection: this.textSelection,
|
|
11238
|
-
selectionRevealType: 1
|
|
11239
|
-
};
|
|
11240
|
-
return textEditorOptions;
|
|
11241
|
-
}
|
|
11242
|
-
log() {
|
|
11243
|
-
return `line: ${this.textSelection.startLineNumber}-${this.textSelection.endLineNumber}, col: ${this.textSelection.startColumn}-${this.textSelection.endColumn}`;
|
|
11244
|
-
}
|
|
11245
|
-
}
|
|
11246
|
-
TextEditorPaneSelection.TEXT_EDITOR_SELECTION_THRESHOLD = 10;
|
|
11247
|
-
function diffSets(before, after) {
|
|
11248
|
-
const removed = [];
|
|
11249
|
-
const added = [];
|
|
11250
|
-
for (let element of before) {
|
|
11251
|
-
if (!after.has(element)) {
|
|
11252
|
-
removed.push(element);
|
|
11253
|
-
}
|
|
11254
|
-
}
|
|
11255
|
-
for (let element of after) {
|
|
11256
|
-
if (!before.has(element)) {
|
|
11257
|
-
added.push(element);
|
|
11258
|
-
}
|
|
11259
|
-
}
|
|
11260
|
-
return { removed, added };
|
|
11261
|
-
}
|
|
11262
|
-
function diffMaps(before, after) {
|
|
11263
|
-
const removed = [];
|
|
11264
|
-
const added = [];
|
|
11265
|
-
for (let [index, value] of before) {
|
|
11266
|
-
if (!after.has(index)) {
|
|
11267
|
-
removed.push(value);
|
|
11268
|
-
}
|
|
11269
|
-
}
|
|
11270
|
-
for (let [index, value] of after) {
|
|
11271
|
-
if (!before.has(index)) {
|
|
11272
|
-
added.push(value);
|
|
11273
|
-
}
|
|
11274
|
-
}
|
|
11275
|
-
return { removed, added };
|
|
11276
|
-
}
|
|
11277
|
-
class TextEditorSnapshot {
|
|
11278
|
-
constructor(editor) {
|
|
11279
|
-
this.editor = editor;
|
|
11280
|
-
this.id = `${editor.getId()},${editor.getModel().id}`;
|
|
11281
|
-
}
|
|
11282
|
-
}
|
|
11283
|
-
class DocumentAndEditorStateDelta {
|
|
11284
|
-
constructor(removedDocuments, addedDocuments, removedEditors, addedEditors, oldActiveEditor, newActiveEditor) {
|
|
11285
|
-
this.removedDocuments = removedDocuments;
|
|
11286
|
-
this.addedDocuments = addedDocuments;
|
|
11287
|
-
this.removedEditors = removedEditors;
|
|
11288
|
-
this.addedEditors = addedEditors;
|
|
11289
|
-
this.oldActiveEditor = oldActiveEditor;
|
|
11290
|
-
this.newActiveEditor = newActiveEditor;
|
|
11291
|
-
this.isEmpty = this.removedDocuments.length === 0
|
|
11292
|
-
&& this.addedDocuments.length === 0
|
|
11293
|
-
&& this.removedEditors.length === 0
|
|
11294
|
-
&& this.addedEditors.length === 0
|
|
11295
|
-
&& oldActiveEditor === newActiveEditor;
|
|
11296
|
-
}
|
|
11297
|
-
toString() {
|
|
11298
|
-
let ret = 'DocumentAndEditorStateDelta\n';
|
|
11299
|
-
ret += `\tRemoved Documents: [${this.removedDocuments.map(d => d.uri.toString(true)).join(', ')}]\n`;
|
|
11300
|
-
ret += `\tAdded Documents: [${this.addedDocuments.map(d => d.uri.toString(true)).join(', ')}]\n`;
|
|
11301
|
-
ret += `\tRemoved Editors: [${this.removedEditors.map(e => e.id).join(', ')}]\n`;
|
|
11302
|
-
ret += `\tAdded Editors: [${this.addedEditors.map(e => e.id).join(', ')}]\n`;
|
|
11303
|
-
ret += `\tNew Active Editor: ${this.newActiveEditor}\n`;
|
|
11304
|
-
return ret;
|
|
11305
|
-
}
|
|
11306
|
-
}
|
|
11307
|
-
class DocumentAndEditorState {
|
|
11308
|
-
constructor(documents, textEditors, activeEditor) {
|
|
11309
|
-
this.documents = documents;
|
|
11310
|
-
this.textEditors = textEditors;
|
|
11311
|
-
this.activeEditor = activeEditor;
|
|
10308
|
+
class DocumentAndEditorState {
|
|
10309
|
+
constructor(documents, textEditors, activeEditor) {
|
|
10310
|
+
this.documents = documents;
|
|
10311
|
+
this.textEditors = textEditors;
|
|
10312
|
+
this.activeEditor = activeEditor;
|
|
11312
10313
|
}
|
|
11313
10314
|
static compute(before, after) {
|
|
11314
10315
|
if (!before) {
|
|
@@ -11456,7 +10457,12 @@ let MainThreadDocumentAndEditorStateComputer = class MainThreadDocumentAndEditor
|
|
|
11456
10457
|
return activeTextEditorControl;
|
|
11457
10458
|
}
|
|
11458
10459
|
};
|
|
11459
|
-
MainThreadDocumentAndEditorStateComputer =
|
|
10460
|
+
MainThreadDocumentAndEditorStateComputer = __decorate([
|
|
10461
|
+
__param(1, IModelService),
|
|
10462
|
+
__param(2, ICodeEditorService),
|
|
10463
|
+
__param(3, IEditorService),
|
|
10464
|
+
__param(4, IPaneCompositePartService)
|
|
10465
|
+
], MainThreadDocumentAndEditorStateComputer);
|
|
11460
10466
|
let MainThreadDocumentsAndEditors = class MainThreadDocumentsAndEditors {
|
|
11461
10467
|
constructor(extHostContext, _modelService, _textFileService, _editorService, codeEditorService, fileService, textModelResolverService, _editorGroupService, bulkEditService, paneCompositeService, environmentService, workingCopyFileService, uriIdentityService, _clipboardService, pathService) {
|
|
11462
10468
|
this._modelService = _modelService;
|
|
@@ -11596,7 +10602,23 @@ let MainThreadDocumentsAndEditors = class MainThreadDocumentsAndEditors {
|
|
|
11596
10602
|
return this._textEditors.get(id);
|
|
11597
10603
|
}
|
|
11598
10604
|
};
|
|
11599
|
-
MainThreadDocumentsAndEditors =
|
|
10605
|
+
MainThreadDocumentsAndEditors = __decorate([
|
|
10606
|
+
extHostCustomer,
|
|
10607
|
+
__param(1, IModelService),
|
|
10608
|
+
__param(2, ITextFileService),
|
|
10609
|
+
__param(3, IEditorService),
|
|
10610
|
+
__param(4, ICodeEditorService),
|
|
10611
|
+
__param(5, IFileService),
|
|
10612
|
+
__param(6, ITextModelService),
|
|
10613
|
+
__param(7, IEditorGroupsService),
|
|
10614
|
+
__param(8, IBulkEditService),
|
|
10615
|
+
__param(9, IPaneCompositePartService),
|
|
10616
|
+
__param(10, IWorkbenchEnvironmentService),
|
|
10617
|
+
__param(11, IWorkingCopyFileService),
|
|
10618
|
+
__param(12, IUriIdentityService),
|
|
10619
|
+
__param(13, IClipboardService),
|
|
10620
|
+
__param(14, IPathService)
|
|
10621
|
+
], MainThreadDocumentsAndEditors);
|
|
11600
10622
|
let MainThreadDiagnostics = class MainThreadDiagnostics {
|
|
11601
10623
|
constructor(extHostContext, _markerService, _uriIdentService) {
|
|
11602
10624
|
this._markerService = _markerService;
|
|
@@ -11652,7 +10674,13 @@ let MainThreadDiagnostics = class MainThreadDiagnostics {
|
|
|
11652
10674
|
this._activeOwners.delete(owner);
|
|
11653
10675
|
}
|
|
11654
10676
|
};
|
|
11655
|
-
MainThreadDiagnostics =
|
|
10677
|
+
MainThreadDiagnostics = __decorate([
|
|
10678
|
+
extHostNamedCustomer(MainContext.MainThreadDiagnostics),
|
|
10679
|
+
__param(1, IMarkerService),
|
|
10680
|
+
__param(2, IUriIdentityService)
|
|
10681
|
+
], MainThreadDiagnostics);
|
|
10682
|
+
const TELEMETRY_SETTING_ID = 'telemetry.telemetryLevel';
|
|
10683
|
+
const TELEMETRY_OLD_SETTING_ID = 'telemetry.enableTelemetry';
|
|
11656
10684
|
function supportsTelemetry(productService, environmentService) {
|
|
11657
10685
|
return !(environmentService.disableTelemetry || !productService.enableTelemetry || environmentService.extensionTestsLocationURI);
|
|
11658
10686
|
}
|
|
@@ -11707,7 +10735,13 @@ let MainThreadTelemetry = MainThreadTelemetry_1 = class MainThreadTelemetry exte
|
|
|
11707
10735
|
}
|
|
11708
10736
|
};
|
|
11709
10737
|
MainThreadTelemetry._name = 'pluginHostTelemetry';
|
|
11710
|
-
MainThreadTelemetry = MainThreadTelemetry_1 =
|
|
10738
|
+
MainThreadTelemetry = MainThreadTelemetry_1 = __decorate([
|
|
10739
|
+
extHostNamedCustomer(MainContext.MainThreadTelemetry),
|
|
10740
|
+
__param(1, ITelemetryService),
|
|
10741
|
+
__param(2, IConfigurationService),
|
|
10742
|
+
__param(3, IEnvironmentService),
|
|
10743
|
+
__param(4, IProductService)
|
|
10744
|
+
], MainThreadTelemetry);
|
|
11711
10745
|
let ExtHostBulkEdits = class ExtHostBulkEdits {
|
|
11712
10746
|
constructor(extHostRpc, extHostDocumentsAndEditors) {
|
|
11713
10747
|
this._proxy = extHostRpc.getProxy(MainContext.MainThreadBulkEdits);
|
|
@@ -11721,7 +10755,9 @@ let ExtHostBulkEdits = class ExtHostBulkEdits {
|
|
|
11721
10755
|
return this._proxy.$tryApplyWorkspaceEdit(dto);
|
|
11722
10756
|
}
|
|
11723
10757
|
};
|
|
11724
|
-
ExtHostBulkEdits =
|
|
10758
|
+
ExtHostBulkEdits = __decorate([
|
|
10759
|
+
__param(0, IExtHostRpcService)
|
|
10760
|
+
], ExtHostBulkEdits);
|
|
11725
10761
|
let MainThreadBulkEdits = class MainThreadBulkEdits {
|
|
11726
10762
|
constructor(_extHostContext, _bulkEditService, _logService) {
|
|
11727
10763
|
this._bulkEditService = _bulkEditService;
|
|
@@ -11736,7 +10772,11 @@ let MainThreadBulkEdits = class MainThreadBulkEdits {
|
|
|
11736
10772
|
});
|
|
11737
10773
|
}
|
|
11738
10774
|
};
|
|
11739
|
-
MainThreadBulkEdits =
|
|
10775
|
+
MainThreadBulkEdits = __decorate([
|
|
10776
|
+
extHostNamedCustomer(MainContext.MainThreadBulkEdits),
|
|
10777
|
+
__param(1, IBulkEditService),
|
|
10778
|
+
__param(2, ILogService)
|
|
10779
|
+
], MainThreadBulkEdits);
|
|
11740
10780
|
class ExtHostLanguages {
|
|
11741
10781
|
constructor(mainContext, _documents, _commands, _uriTransformer) {
|
|
11742
10782
|
this._documents = _documents;
|
|
@@ -11955,7 +10995,13 @@ let MainThreadLanguages = class MainThreadLanguages {
|
|
|
11955
10995
|
this._status.get(handle)?.dispose();
|
|
11956
10996
|
}
|
|
11957
10997
|
};
|
|
11958
|
-
MainThreadLanguages =
|
|
10998
|
+
MainThreadLanguages = __decorate([
|
|
10999
|
+
extHostNamedCustomer(MainContext.MainThreadLanguages),
|
|
11000
|
+
__param(1, ILanguageService),
|
|
11001
|
+
__param(2, IModelService),
|
|
11002
|
+
__param(3, ITextModelService),
|
|
11003
|
+
__param(4, ILanguageStatusService)
|
|
11004
|
+
], MainThreadLanguages);
|
|
11959
11005
|
class URITransformerService {
|
|
11960
11006
|
constructor(delegate) {
|
|
11961
11007
|
if (!delegate) {
|
|
@@ -11993,7 +11039,7 @@ let ExtHostWindow = class ExtHostWindow {
|
|
|
11993
11039
|
if (typeof stringOrUri === 'string') {
|
|
11994
11040
|
uriAsString = stringOrUri;
|
|
11995
11041
|
try {
|
|
11996
|
-
stringOrUri =
|
|
11042
|
+
stringOrUri = URI.parse(stringOrUri);
|
|
11997
11043
|
}
|
|
11998
11044
|
catch (e) {
|
|
11999
11045
|
return Promise.reject(`Invalid uri - '${stringOrUri}'`);
|
|
@@ -12018,7 +11064,9 @@ let ExtHostWindow = class ExtHostWindow {
|
|
|
12018
11064
|
ExtHostWindow.InitialState = {
|
|
12019
11065
|
focused: true
|
|
12020
11066
|
};
|
|
12021
|
-
ExtHostWindow =
|
|
11067
|
+
ExtHostWindow = __decorate([
|
|
11068
|
+
__param(0, IExtHostRpcService)
|
|
11069
|
+
], ExtHostWindow);
|
|
12022
11070
|
let MainThreadWindow = class MainThreadWindow {
|
|
12023
11071
|
constructor(extHostContext, hostService, openerService) {
|
|
12024
11072
|
this.hostService = hostService;
|
|
@@ -12041,7 +11089,7 @@ let MainThreadWindow = class MainThreadWindow {
|
|
|
12041
11089
|
async $openUri(uriComponents, uriString, options) {
|
|
12042
11090
|
const uri = URI.from(uriComponents);
|
|
12043
11091
|
let target;
|
|
12044
|
-
if (uriString &&
|
|
11092
|
+
if (uriString && URI.parse(uriString).toString() === uri.toString()) {
|
|
12045
11093
|
target = uriString;
|
|
12046
11094
|
}
|
|
12047
11095
|
else {
|
|
@@ -12058,338 +11106,11 @@ let MainThreadWindow = class MainThreadWindow {
|
|
|
12058
11106
|
return result.resolved;
|
|
12059
11107
|
}
|
|
12060
11108
|
};
|
|
12061
|
-
MainThreadWindow =
|
|
12062
|
-
|
|
12063
|
-
|
|
12064
|
-
|
|
12065
|
-
|
|
12066
|
-
constructor() {
|
|
12067
|
-
this._serviceBrand = undefined;
|
|
12068
|
-
this.onDidActiveEditorChange = Event.None;
|
|
12069
|
-
this.onDidVisibleEditorsChange = Event.None;
|
|
12070
|
-
this.onDidEditorsChange = Event.None;
|
|
12071
|
-
this.onDidCloseEditor = Event.None;
|
|
12072
|
-
this.activeEditorPane = undefined;
|
|
12073
|
-
this.activeEditor = undefined;
|
|
12074
|
-
this.activeTextEditorControl = undefined;
|
|
12075
|
-
this.activeTextEditorLanguageId = undefined;
|
|
12076
|
-
this.visibleEditorPanes = [];
|
|
12077
|
-
this.visibleEditors = [];
|
|
12078
|
-
this.visibleTextEditorControls = [];
|
|
12079
|
-
this.editors = [];
|
|
12080
|
-
this.count = 0;
|
|
12081
|
-
this.getEditors = () => [];
|
|
12082
|
-
this.openEditor = unsupported$1;
|
|
12083
|
-
this.openEditors = async () => [];
|
|
12084
|
-
this.replaceEditors = async () => { };
|
|
12085
|
-
this.isOpened = () => false;
|
|
12086
|
-
this.isVisible = () => false;
|
|
12087
|
-
this.closeEditor = async () => { };
|
|
12088
|
-
this.closeEditors = async () => { };
|
|
12089
|
-
this.findEditors = () => [];
|
|
12090
|
-
this.save = async () => false;
|
|
12091
|
-
this.saveAll = async () => false;
|
|
12092
|
-
this.revert = async () => false;
|
|
12093
|
-
this.revertAll = async () => false;
|
|
12094
|
-
}
|
|
12095
|
-
});
|
|
12096
|
-
registerSingleton(IPaneCompositePartService, class PaneCompositePartService {
|
|
12097
|
-
constructor() {
|
|
12098
|
-
this._serviceBrand = undefined;
|
|
12099
|
-
this.onDidPaneCompositeOpen = Event.None;
|
|
12100
|
-
this.onDidPaneCompositeClose = Event.None;
|
|
12101
|
-
this.openPaneComposite = unsupported$1;
|
|
12102
|
-
this.getActivePaneComposite = () => undefined;
|
|
12103
|
-
this.getPaneComposite = () => undefined;
|
|
12104
|
-
this.getPaneComposites = () => [];
|
|
12105
|
-
this.getPinnedPaneCompositeIds = () => [];
|
|
12106
|
-
this.getVisiblePaneCompositeIds = () => [];
|
|
12107
|
-
this.getProgressIndicator = () => undefined;
|
|
12108
|
-
this.hideActivePaneComposite = () => { };
|
|
12109
|
-
this.getLastActivePaneCompositeId = unsupported$1;
|
|
12110
|
-
this.showActivity = unsupported$1;
|
|
12111
|
-
}
|
|
12112
|
-
});
|
|
12113
|
-
registerSingleton(IUriIdentityService, class UriIdentityService {
|
|
12114
|
-
constructor() {
|
|
12115
|
-
this._serviceBrand = undefined;
|
|
12116
|
-
this.extUri = new ExtUri$1(() => false);
|
|
12117
|
-
}
|
|
12118
|
-
asCanonicalUri(uri) {
|
|
12119
|
-
return uri;
|
|
12120
|
-
}
|
|
12121
|
-
});
|
|
12122
|
-
const onDidSave = new Emitter();
|
|
12123
|
-
class TextFileEditorModelManager {
|
|
12124
|
-
constructor() {
|
|
12125
|
-
this.onDidCreate = Event.None;
|
|
12126
|
-
this.onDidResolve = Event.None;
|
|
12127
|
-
this.onDidChangeDirty = Event.None;
|
|
12128
|
-
this.onDidChangeReadonly = Event.None;
|
|
12129
|
-
this.onDidRemove = Event.None;
|
|
12130
|
-
this.onDidChangeOrphaned = Event.None;
|
|
12131
|
-
this.onDidChangeEncoding = Event.None;
|
|
12132
|
-
this.onDidSaveError = Event.None;
|
|
12133
|
-
this.onDidSave = onDidSave.event;
|
|
12134
|
-
this.onDidRevert = Event.None;
|
|
12135
|
-
this.models = [];
|
|
12136
|
-
this.saveErrorHandler = {
|
|
12137
|
-
onSaveError: unsupported$1
|
|
12138
|
-
};
|
|
12139
|
-
this.get = () => undefined;
|
|
12140
|
-
this.resolve = unsupported$1;
|
|
12141
|
-
this.addSaveParticipant = unsupported$1;
|
|
12142
|
-
this.runSaveParticipants = unsupported$1;
|
|
12143
|
-
}
|
|
12144
|
-
canDispose() {
|
|
12145
|
-
return true;
|
|
12146
|
-
}
|
|
12147
|
-
}
|
|
12148
|
-
registerSingleton(ITextFileService, class TextFileService {
|
|
12149
|
-
constructor() {
|
|
12150
|
-
this._serviceBrand = undefined;
|
|
12151
|
-
this.files = new TextFileEditorModelManager();
|
|
12152
|
-
this.isDirty = () => false;
|
|
12153
|
-
this.save = unsupported$1;
|
|
12154
|
-
this.saveAs = unsupported$1;
|
|
12155
|
-
this.revert = unsupported$1;
|
|
12156
|
-
this.read = unsupported$1;
|
|
12157
|
-
this.readStream = unsupported$1;
|
|
12158
|
-
this.write = unsupported$1;
|
|
12159
|
-
this.create = unsupported$1;
|
|
12160
|
-
this.getEncodedReadable = unsupported$1;
|
|
12161
|
-
this.getDecodedStream = unsupported$1;
|
|
12162
|
-
}
|
|
12163
|
-
get untitled() { return unsupported$1(); }
|
|
12164
|
-
get encoding() { return unsupported$1(); }
|
|
12165
|
-
dispose() {
|
|
12166
|
-
}
|
|
12167
|
-
});
|
|
12168
|
-
registerSingleton(IFileService, class FileService {
|
|
12169
|
-
constructor() {
|
|
12170
|
-
this._serviceBrand = undefined;
|
|
12171
|
-
this.onDidChangeFileSystemProviderRegistrations = Event.None;
|
|
12172
|
-
this.onDidChangeFileSystemProviderCapabilities = Event.None;
|
|
12173
|
-
this.onWillActivateFileSystemProvider = Event.None;
|
|
12174
|
-
this.registerProvider = unsupported$1;
|
|
12175
|
-
this.getProvider = function () {
|
|
12176
|
-
return undefined;
|
|
12177
|
-
};
|
|
12178
|
-
this.activateProvider = unsupported$1;
|
|
12179
|
-
this.canHandleResource = async () => false;
|
|
12180
|
-
this.hasProvider = () => false;
|
|
12181
|
-
this.hasCapability = () => false;
|
|
12182
|
-
this.listCapabilities = () => [];
|
|
12183
|
-
this.onDidFilesChange = Event.None;
|
|
12184
|
-
this.onDidRunOperation = Event.None;
|
|
12185
|
-
this.resolve = unsupported$1;
|
|
12186
|
-
this.resolveAll = unsupported$1;
|
|
12187
|
-
this.stat = unsupported$1;
|
|
12188
|
-
this.exists = async () => false;
|
|
12189
|
-
this.readFile = unsupported$1;
|
|
12190
|
-
this.readFileStream = unsupported$1;
|
|
12191
|
-
this.writeFile = unsupported$1;
|
|
12192
|
-
this.move = unsupported$1;
|
|
12193
|
-
this.canMove = unsupported$1;
|
|
12194
|
-
this.copy = unsupported$1;
|
|
12195
|
-
this.canCopy = unsupported$1;
|
|
12196
|
-
this.cloneFile = unsupported$1;
|
|
12197
|
-
this.createFile = unsupported$1;
|
|
12198
|
-
this.canCreateFile = unsupported$1;
|
|
12199
|
-
this.createFolder = unsupported$1;
|
|
12200
|
-
this.del = unsupported$1;
|
|
12201
|
-
this.canDelete = unsupported$1;
|
|
12202
|
-
this.onDidWatchError = Event.None;
|
|
12203
|
-
this.watch = unsupported$1;
|
|
12204
|
-
}
|
|
12205
|
-
dispose() {
|
|
12206
|
-
}
|
|
12207
|
-
});
|
|
12208
|
-
registerSingleton(IEditorGroupsService, class EditorGroupsService {
|
|
12209
|
-
constructor() {
|
|
12210
|
-
this._serviceBrand = undefined;
|
|
12211
|
-
this.onDidChangeActiveGroup = Event.None;
|
|
12212
|
-
this.onDidAddGroup = Event.None;
|
|
12213
|
-
this.onDidRemoveGroup = Event.None;
|
|
12214
|
-
this.onDidMoveGroup = Event.None;
|
|
12215
|
-
this.onDidActivateGroup = Event.None;
|
|
12216
|
-
this.onDidLayout = Event.None;
|
|
12217
|
-
this.onDidScroll = Event.None;
|
|
12218
|
-
this.onDidChangeGroupIndex = Event.None;
|
|
12219
|
-
this.onDidChangeGroupLocked = Event.None;
|
|
12220
|
-
this.groups = [];
|
|
12221
|
-
this.count = 0;
|
|
12222
|
-
this.orientation = 0 ;
|
|
12223
|
-
this.isReady = false;
|
|
12224
|
-
this.whenReady = Promise.resolve();
|
|
12225
|
-
this.whenRestored = Promise.resolve();
|
|
12226
|
-
this.hasRestorableState = false;
|
|
12227
|
-
this.getGroups = () => [];
|
|
12228
|
-
this.getGroup = () => undefined;
|
|
12229
|
-
this.activateGroup = unsupported$1;
|
|
12230
|
-
this.getSize = unsupported$1;
|
|
12231
|
-
this.setSize = unsupported$1;
|
|
12232
|
-
this.arrangeGroups = unsupported$1;
|
|
12233
|
-
this.applyLayout = unsupported$1;
|
|
12234
|
-
this.centerLayout = unsupported$1;
|
|
12235
|
-
this.isLayoutCentered = () => false;
|
|
12236
|
-
this.setGroupOrientation = unsupported$1;
|
|
12237
|
-
this.findGroup = () => undefined;
|
|
12238
|
-
this.addGroup = unsupported$1;
|
|
12239
|
-
this.removeGroup = unsupported$1;
|
|
12240
|
-
this.moveGroup = unsupported$1;
|
|
12241
|
-
this.mergeGroup = unsupported$1;
|
|
12242
|
-
this.mergeAllGroups = unsupported$1;
|
|
12243
|
-
this.copyGroup = unsupported$1;
|
|
12244
|
-
this.onDidChangeEditorPartOptions = Event.None;
|
|
12245
|
-
this.enforcePartOptions = unsupported$1;
|
|
12246
|
-
}
|
|
12247
|
-
get contentDimension() { return unsupported$1(); }
|
|
12248
|
-
get activeGroup() { return unsupported$1(); }
|
|
12249
|
-
get sideGroup() { return unsupported$1(); }
|
|
12250
|
-
get partOptions() { return unsupported$1(); }
|
|
12251
|
-
});
|
|
12252
|
-
registerSingleton(IWorkbenchEnvironmentService, class WorkbenchEnvironmentService {
|
|
12253
|
-
constructor() {
|
|
12254
|
-
this._serviceBrand = undefined;
|
|
12255
|
-
this.skipReleaseNotes = true;
|
|
12256
|
-
this.skipWelcome = true;
|
|
12257
|
-
this.disableWorkspaceTrust = true;
|
|
12258
|
-
this.debugRenderer = false;
|
|
12259
|
-
this.sync = undefined;
|
|
12260
|
-
this.isExtensionDevelopment = false;
|
|
12261
|
-
this.disableExtensions = false;
|
|
12262
|
-
this.logsPath = '';
|
|
12263
|
-
this.verbose = false;
|
|
12264
|
-
this.isBuilt = false;
|
|
12265
|
-
this.disableTelemetry = false;
|
|
12266
|
-
}
|
|
12267
|
-
get logFile() { return unsupported$1(); }
|
|
12268
|
-
get extHostLogsPath() { return unsupported$1(); }
|
|
12269
|
-
get webviewExternalEndpoint() { return unsupported$1(); }
|
|
12270
|
-
get userRoamingDataHome() { return unsupported$1(); }
|
|
12271
|
-
get settingsResource() { return unsupported$1(); }
|
|
12272
|
-
get keybindingsResource() { return unsupported$1(); }
|
|
12273
|
-
get keyboardLayoutResource() { return unsupported$1(); }
|
|
12274
|
-
get argvResource() { return unsupported$1(); }
|
|
12275
|
-
get snippetsHome() { return unsupported$1(); }
|
|
12276
|
-
get untitledWorkspacesHome() { return unsupported$1(); }
|
|
12277
|
-
get globalStorageHome() { return unsupported$1(); }
|
|
12278
|
-
get workspaceStorageHome() { return unsupported$1(); }
|
|
12279
|
-
get localHistoryHome() { return unsupported$1(); }
|
|
12280
|
-
get cacheHome() { return unsupported$1(); }
|
|
12281
|
-
get userDataSyncHome() { return unsupported$1(); }
|
|
12282
|
-
get userDataSyncLogResource() { return unsupported$1(); }
|
|
12283
|
-
get debugExtensionHost() { return unsupported$1(); }
|
|
12284
|
-
get telemetryLogResource() { return unsupported$1(); }
|
|
12285
|
-
get serviceMachineIdResource() { return unsupported$1(); }
|
|
12286
|
-
});
|
|
12287
|
-
registerSingleton(IWorkingCopyFileService, class WorkingCopyFileService {
|
|
12288
|
-
constructor() {
|
|
12289
|
-
this._serviceBrand = undefined;
|
|
12290
|
-
this.onWillRunWorkingCopyFileOperation = Event.None;
|
|
12291
|
-
this.onDidFailWorkingCopyFileOperation = Event.None;
|
|
12292
|
-
this.onDidRunWorkingCopyFileOperation = Event.None;
|
|
12293
|
-
this.addFileOperationParticipant = unsupported$1;
|
|
12294
|
-
this.hasSaveParticipants = false;
|
|
12295
|
-
this.addSaveParticipant = unsupported$1;
|
|
12296
|
-
this.runSaveParticipants = unsupported$1;
|
|
12297
|
-
this.create = unsupported$1;
|
|
12298
|
-
this.createFolder = unsupported$1;
|
|
12299
|
-
this.move = unsupported$1;
|
|
12300
|
-
this.copy = unsupported$1;
|
|
12301
|
-
this.delete = unsupported$1;
|
|
12302
|
-
this.registerWorkingCopyProvider = unsupported$1;
|
|
12303
|
-
this.getDirty = unsupported$1;
|
|
12304
|
-
}
|
|
12305
|
-
});
|
|
12306
|
-
registerSingleton(IPathService, class PathService {
|
|
12307
|
-
constructor() {
|
|
12308
|
-
this._serviceBrand = undefined;
|
|
12309
|
-
this.defaultUriScheme = Schemas.file;
|
|
12310
|
-
this.userHome = unsupported$1;
|
|
12311
|
-
this.hasValidBasename = unsupported$1;
|
|
12312
|
-
this.resolvedUserHome = undefined;
|
|
12313
|
-
}
|
|
12314
|
-
get path() { return unsupported$1(); }
|
|
12315
|
-
async fileURI(path) {
|
|
12316
|
-
return URI.file(path);
|
|
12317
|
-
}
|
|
12318
|
-
});
|
|
12319
|
-
registerSingleton(IProgressService, class ProgressService {
|
|
12320
|
-
constructor() {
|
|
12321
|
-
this._serviceBrand = undefined;
|
|
12322
|
-
}
|
|
12323
|
-
withProgress(options, task, onDidCancel) {
|
|
12324
|
-
const { window } = Services.get();
|
|
12325
|
-
if (window?.withProgress != null) {
|
|
12326
|
-
return window.withProgress(options, task, onDidCancel);
|
|
12327
|
-
}
|
|
12328
|
-
return task({ report: () => { } });
|
|
12329
|
-
}
|
|
12330
|
-
});
|
|
12331
|
-
registerSingleton(IProductService, class ProductService {
|
|
12332
|
-
constructor() {
|
|
12333
|
-
this._serviceBrand = undefined;
|
|
12334
|
-
this.version = "1.68.0";
|
|
12335
|
-
this.nameShort = 'Code - OSS Dev';
|
|
12336
|
-
this.nameLong = 'Code - OSS Dev';
|
|
12337
|
-
this.applicationName = 'code-oss';
|
|
12338
|
-
this.dataFolderName = '.vscode-oss';
|
|
12339
|
-
this.urlProtocol = 'code-oss';
|
|
12340
|
-
this.reportIssueUrl = 'https://github.com/microsoft/vscode/issues/new';
|
|
12341
|
-
this.licenseName = 'MIT';
|
|
12342
|
-
this.licenseUrl = 'https://github.com/microsoft/vscode/blob/main/LICENSE.txt';
|
|
12343
|
-
this.serverApplicationName = 'code-server-oss';
|
|
12344
|
-
}
|
|
12345
|
-
});
|
|
12346
|
-
registerSingleton(ILanguageStatusService, class LanguageStatusServiceImpl {
|
|
12347
|
-
constructor() {
|
|
12348
|
-
this._provider = new LanguageFeatureRegistry();
|
|
12349
|
-
this.onDidChange = this._provider.onDidChange;
|
|
12350
|
-
}
|
|
12351
|
-
addStatus(status) {
|
|
12352
|
-
return this._provider.register(status.selector, status);
|
|
12353
|
-
}
|
|
12354
|
-
getLanguageStatus(model) {
|
|
12355
|
-
return this._provider.ordered(model).sort((a, b) => {
|
|
12356
|
-
let res = b.severity - a.severity;
|
|
12357
|
-
if (res === 0) {
|
|
12358
|
-
res = compare(a.source, b.source);
|
|
12359
|
-
}
|
|
12360
|
-
if (res === 0) {
|
|
12361
|
-
res = compare(a.id, b.id);
|
|
12362
|
-
}
|
|
12363
|
-
return res;
|
|
12364
|
-
});
|
|
12365
|
-
}
|
|
12366
|
-
});
|
|
12367
|
-
registerSingleton(IHostService, class HostService {
|
|
12368
|
-
constructor() {
|
|
12369
|
-
this.onDidChangeFocus = Event.None;
|
|
12370
|
-
this.openWindow = unsupported$1;
|
|
12371
|
-
this.restart = unsupported$1;
|
|
12372
|
-
this.reload = unsupported$1;
|
|
12373
|
-
this.close = unsupported$1;
|
|
12374
|
-
}
|
|
12375
|
-
get hasFocus() {
|
|
12376
|
-
return document.hasFocus();
|
|
12377
|
-
}
|
|
12378
|
-
async hadLastFocus() {
|
|
12379
|
-
return true;
|
|
12380
|
-
}
|
|
12381
|
-
async focus() {
|
|
12382
|
-
window.focus();
|
|
12383
|
-
}
|
|
12384
|
-
async toggleFullScreen() {
|
|
12385
|
-
if (document.fullscreenEnabled) {
|
|
12386
|
-
await document.body.requestFullscreen();
|
|
12387
|
-
}
|
|
12388
|
-
else {
|
|
12389
|
-
await document.exitFullscreen();
|
|
12390
|
-
}
|
|
12391
|
-
}
|
|
12392
|
-
});
|
|
11109
|
+
MainThreadWindow = __decorate([
|
|
11110
|
+
extHostNamedCustomer(MainContext.MainThreadWindow),
|
|
11111
|
+
__param(1, IHostService),
|
|
11112
|
+
__param(2, IOpenerService)
|
|
11113
|
+
], MainThreadWindow);
|
|
12393
11114
|
let MainThreadClipboard = class MainThreadClipboard {
|
|
12394
11115
|
constructor(_context, _clipboardService) {
|
|
12395
11116
|
this._clipboardService = _clipboardService;
|
|
@@ -12403,11 +11124,14 @@ let MainThreadClipboard = class MainThreadClipboard {
|
|
|
12403
11124
|
return this._clipboardService.writeText(value);
|
|
12404
11125
|
}
|
|
12405
11126
|
};
|
|
12406
|
-
MainThreadClipboard =
|
|
11127
|
+
MainThreadClipboard = __decorate([
|
|
11128
|
+
extHostNamedCustomer(MainContext.MainThreadClipboard),
|
|
11129
|
+
__param(1, IClipboardService)
|
|
11130
|
+
], MainThreadClipboard);
|
|
12407
11131
|
class ExtHostClipboard {
|
|
12408
11132
|
constructor(mainContext) {
|
|
12409
11133
|
const proxy = mainContext.getProxy(MainContext.MainThreadClipboard);
|
|
12410
|
-
this.value =
|
|
11134
|
+
this.value = Object.freeze({
|
|
12411
11135
|
readText() {
|
|
12412
11136
|
return proxy.$readText();
|
|
12413
11137
|
},
|
|
@@ -13048,7 +11772,7 @@ class RenameAdapter {
|
|
|
13048
11772
|
range = rangeOrLocation;
|
|
13049
11773
|
text = doc.getText(rangeOrLocation);
|
|
13050
11774
|
}
|
|
13051
|
-
else if (isObject
|
|
11775
|
+
else if (isObject(rangeOrLocation)) {
|
|
13052
11776
|
range = rangeOrLocation.range;
|
|
13053
11777
|
text = rangeOrLocation.placeholder;
|
|
13054
11778
|
}
|
|
@@ -14492,7 +13216,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
14492
13216
|
return data;
|
|
14493
13217
|
}
|
|
14494
13218
|
$registerDocumentSymbolProvider(handle, selector, displayName) {
|
|
14495
|
-
this._registrations.set(handle,
|
|
13219
|
+
this._registrations.set(handle, this._languageFeaturesService.documentSymbolProvider.register(selector, {
|
|
14496
13220
|
displayName,
|
|
14497
13221
|
provideDocumentSymbols: (model, token) => {
|
|
14498
13222
|
return this._proxy.$provideDocumentSymbols(handle, model.uri, token);
|
|
@@ -14520,7 +13244,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
14520
13244
|
this._registrations.set(eventHandle, emitter);
|
|
14521
13245
|
provider.onDidChange = emitter.event;
|
|
14522
13246
|
}
|
|
14523
|
-
this._registrations.set(handle,
|
|
13247
|
+
this._registrations.set(handle, this._languageFeaturesService.codeLensProvider.register(selector, provider));
|
|
14524
13248
|
}
|
|
14525
13249
|
$emitCodeLensEvent(eventHandle, event) {
|
|
14526
13250
|
const obj = this._registrations.get(eventHandle);
|
|
@@ -14529,42 +13253,42 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
14529
13253
|
}
|
|
14530
13254
|
}
|
|
14531
13255
|
$registerDefinitionSupport(handle, selector) {
|
|
14532
|
-
this._registrations.set(handle,
|
|
13256
|
+
this._registrations.set(handle, this._languageFeaturesService.definitionProvider.register(selector, {
|
|
14533
13257
|
provideDefinition: (model, position, token) => {
|
|
14534
13258
|
return this._proxy.$provideDefinition(handle, model.uri, position, token).then(MainThreadLanguageFeatures_1._reviveLocationLinkDto);
|
|
14535
13259
|
}
|
|
14536
13260
|
}));
|
|
14537
13261
|
}
|
|
14538
13262
|
$registerDeclarationSupport(handle, selector) {
|
|
14539
|
-
this._registrations.set(handle,
|
|
13263
|
+
this._registrations.set(handle, this._languageFeaturesService.declarationProvider.register(selector, {
|
|
14540
13264
|
provideDeclaration: (model, position, token) => {
|
|
14541
13265
|
return this._proxy.$provideDeclaration(handle, model.uri, position, token).then(MainThreadLanguageFeatures_1._reviveLocationLinkDto);
|
|
14542
13266
|
}
|
|
14543
13267
|
}));
|
|
14544
13268
|
}
|
|
14545
13269
|
$registerImplementationSupport(handle, selector) {
|
|
14546
|
-
this._registrations.set(handle,
|
|
13270
|
+
this._registrations.set(handle, this._languageFeaturesService.implementationProvider.register(selector, {
|
|
14547
13271
|
provideImplementation: (model, position, token) => {
|
|
14548
13272
|
return this._proxy.$provideImplementation(handle, model.uri, position, token).then(MainThreadLanguageFeatures_1._reviveLocationLinkDto);
|
|
14549
13273
|
}
|
|
14550
13274
|
}));
|
|
14551
13275
|
}
|
|
14552
13276
|
$registerTypeDefinitionSupport(handle, selector) {
|
|
14553
|
-
this._registrations.set(handle,
|
|
13277
|
+
this._registrations.set(handle, this._languageFeaturesService.typeDefinitionProvider.register(selector, {
|
|
14554
13278
|
provideTypeDefinition: (model, position, token) => {
|
|
14555
13279
|
return this._proxy.$provideTypeDefinition(handle, model.uri, position, token).then(MainThreadLanguageFeatures_1._reviveLocationLinkDto);
|
|
14556
13280
|
}
|
|
14557
13281
|
}));
|
|
14558
13282
|
}
|
|
14559
13283
|
$registerHoverProvider(handle, selector) {
|
|
14560
|
-
this._registrations.set(handle,
|
|
13284
|
+
this._registrations.set(handle, this._languageFeaturesService.hoverProvider.register(selector, {
|
|
14561
13285
|
provideHover: (model, position, token) => {
|
|
14562
13286
|
return this._proxy.$provideHover(handle, model.uri, position, token);
|
|
14563
13287
|
}
|
|
14564
13288
|
}));
|
|
14565
13289
|
}
|
|
14566
13290
|
$registerEvaluatableExpressionProvider(handle, selector) {
|
|
14567
|
-
this._registrations.set(handle,
|
|
13291
|
+
this._registrations.set(handle, this._languageFeaturesService.evaluatableExpressionProvider.register(selector, {
|
|
14568
13292
|
provideEvaluatableExpression: (model, position, token) => {
|
|
14569
13293
|
return this._proxy.$provideEvaluatableExpression(handle, model.uri, position, token);
|
|
14570
13294
|
}
|
|
@@ -14581,7 +13305,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
14581
13305
|
this._registrations.set(eventHandle, emitter);
|
|
14582
13306
|
provider.onDidChangeInlineValues = emitter.event;
|
|
14583
13307
|
}
|
|
14584
|
-
this._registrations.set(handle,
|
|
13308
|
+
this._registrations.set(handle, this._languageFeaturesService.inlineValuesProvider.register(selector, provider));
|
|
14585
13309
|
}
|
|
14586
13310
|
$emitInlineValuesEvent(eventHandle, event) {
|
|
14587
13311
|
const obj = this._registrations.get(eventHandle);
|
|
@@ -14590,14 +13314,14 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
14590
13314
|
}
|
|
14591
13315
|
}
|
|
14592
13316
|
$registerDocumentHighlightProvider(handle, selector) {
|
|
14593
|
-
this._registrations.set(handle,
|
|
13317
|
+
this._registrations.set(handle, this._languageFeaturesService.documentHighlightProvider.register(selector, {
|
|
14594
13318
|
provideDocumentHighlights: (model, position, token) => {
|
|
14595
13319
|
return this._proxy.$provideDocumentHighlights(handle, model.uri, position, token);
|
|
14596
13320
|
}
|
|
14597
13321
|
}));
|
|
14598
13322
|
}
|
|
14599
13323
|
$registerLinkedEditingRangeProvider(handle, selector) {
|
|
14600
|
-
this._registrations.set(handle,
|
|
13324
|
+
this._registrations.set(handle, this._languageFeaturesService.linkedEditingRangeProvider.register(selector, {
|
|
14601
13325
|
provideLinkedEditingRanges: async (model, position, token) => {
|
|
14602
13326
|
const res = await this._proxy.$provideLinkedEditingRanges(handle, model.uri, position, token);
|
|
14603
13327
|
if (res) {
|
|
@@ -14611,7 +13335,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
14611
13335
|
}));
|
|
14612
13336
|
}
|
|
14613
13337
|
$registerReferenceSupport(handle, selector) {
|
|
14614
|
-
this._registrations.set(handle,
|
|
13338
|
+
this._registrations.set(handle, this._languageFeaturesService.referenceProvider.register(selector, {
|
|
14615
13339
|
provideReferences: (model, position, context, token) => {
|
|
14616
13340
|
return this._proxy.$provideReferences(handle, model.uri, position, context, token).then(MainThreadLanguageFeatures_1._reviveLocationDto);
|
|
14617
13341
|
}
|
|
@@ -14644,10 +13368,10 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
14644
13368
|
return codeAction;
|
|
14645
13369
|
};
|
|
14646
13370
|
}
|
|
14647
|
-
this._registrations.set(handle,
|
|
13371
|
+
this._registrations.set(handle, this._languageFeaturesService.codeActionProvider.register(selector, provider));
|
|
14648
13372
|
}
|
|
14649
13373
|
$registerDocumentFormattingSupport(handle, selector, extensionId, displayName) {
|
|
14650
|
-
this._registrations.set(handle,
|
|
13374
|
+
this._registrations.set(handle, this._languageFeaturesService.documentFormattingEditProvider.register(selector, {
|
|
14651
13375
|
extensionId,
|
|
14652
13376
|
displayName,
|
|
14653
13377
|
provideDocumentFormattingEdits: (model, options, token) => {
|
|
@@ -14656,7 +13380,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
14656
13380
|
}));
|
|
14657
13381
|
}
|
|
14658
13382
|
$registerRangeFormattingSupport(handle, selector, extensionId, displayName) {
|
|
14659
|
-
this._registrations.set(handle,
|
|
13383
|
+
this._registrations.set(handle, this._languageFeaturesService.documentRangeFormattingEditProvider.register(selector, {
|
|
14660
13384
|
extensionId,
|
|
14661
13385
|
displayName,
|
|
14662
13386
|
provideDocumentRangeFormattingEdits: (model, range, options, token) => {
|
|
@@ -14665,7 +13389,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
14665
13389
|
}));
|
|
14666
13390
|
}
|
|
14667
13391
|
$registerOnTypeFormattingSupport(handle, selector, autoFormatTriggerCharacters, extensionId) {
|
|
14668
|
-
this._registrations.set(handle,
|
|
13392
|
+
this._registrations.set(handle, this._languageFeaturesService.onTypeFormattingEditProvider.register(selector, {
|
|
14669
13393
|
extensionId,
|
|
14670
13394
|
autoFormatTriggerCharacters,
|
|
14671
13395
|
provideOnTypeFormattingEdits: (model, position, ch, options, token) => {
|
|
@@ -14691,10 +13415,10 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
14691
13415
|
return resolvedItem && MainThreadLanguageFeatures_1._reviveWorkspaceSymbolDto(resolvedItem);
|
|
14692
13416
|
};
|
|
14693
13417
|
}
|
|
14694
|
-
this._registrations.set(handle,
|
|
13418
|
+
this._registrations.set(handle, WorkspaceSymbolProviderRegistry.register(provider));
|
|
14695
13419
|
}
|
|
14696
13420
|
$registerRenameSupport(handle, selector, supportResolveLocation) {
|
|
14697
|
-
this._registrations.set(handle,
|
|
13421
|
+
this._registrations.set(handle, this._languageFeaturesService.renameProvider.register(selector, {
|
|
14698
13422
|
provideRenameEdits: (model, position, newName, token) => {
|
|
14699
13423
|
return this._proxy.$provideRenameEdits(handle, model.uri, position, newName, token).then(reviveWorkspaceEditDto);
|
|
14700
13424
|
},
|
|
@@ -14710,7 +13434,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
14710
13434
|
this._registrations.set(eventHandle, emitter);
|
|
14711
13435
|
event = emitter.event;
|
|
14712
13436
|
}
|
|
14713
|
-
this._registrations.set(handle,
|
|
13437
|
+
this._registrations.set(handle, this._languageFeaturesService.documentSemanticTokensProvider.register(selector, new MainThreadDocumentSemanticTokensProvider(this._proxy, handle, legend, event)));
|
|
14714
13438
|
}
|
|
14715
13439
|
$emitDocumentSemanticTokensEvent(eventHandle) {
|
|
14716
13440
|
const obj = this._registrations.get(eventHandle);
|
|
@@ -14719,7 +13443,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
14719
13443
|
}
|
|
14720
13444
|
}
|
|
14721
13445
|
$registerDocumentRangeSemanticTokensProvider(handle, selector, legend) {
|
|
14722
|
-
this._registrations.set(handle,
|
|
13446
|
+
this._registrations.set(handle, this._languageFeaturesService.documentRangeSemanticTokensProvider.register(selector, new MainThreadDocumentRangeSemanticTokensProvider(this._proxy, handle, legend)));
|
|
14723
13447
|
}
|
|
14724
13448
|
static _inflateSuggestDto(defaultRange, data) {
|
|
14725
13449
|
const label = data["a" ];
|
|
@@ -14773,7 +13497,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
14773
13497
|
});
|
|
14774
13498
|
};
|
|
14775
13499
|
}
|
|
14776
|
-
this._registrations.set(handle,
|
|
13500
|
+
this._registrations.set(handle, this._languageFeaturesService.completionProvider.register(selector, provider));
|
|
14777
13501
|
}
|
|
14778
13502
|
$registerInlineCompletionsSupport(handle, selector) {
|
|
14779
13503
|
const provider = {
|
|
@@ -14787,10 +13511,10 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
14787
13511
|
this._proxy.$freeInlineCompletionsList(handle, completions.pid);
|
|
14788
13512
|
}
|
|
14789
13513
|
};
|
|
14790
|
-
this._registrations.set(handle,
|
|
13514
|
+
this._registrations.set(handle, this._languageFeaturesService.inlineCompletionsProvider.register(selector, provider));
|
|
14791
13515
|
}
|
|
14792
13516
|
$registerSignatureHelpProvider(handle, selector, metadata) {
|
|
14793
|
-
this._registrations.set(handle,
|
|
13517
|
+
this._registrations.set(handle, this._languageFeaturesService.signatureHelpProvider.register(selector, {
|
|
14794
13518
|
signatureHelpTriggerCharacters: metadata.triggerCharacters,
|
|
14795
13519
|
signatureHelpRetriggerCharacters: metadata.retriggerCharacters,
|
|
14796
13520
|
provideSignatureHelp: async (model, position, token, context) => {
|
|
@@ -14850,7 +13574,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
14850
13574
|
this._registrations.set(eventHandle, emitter);
|
|
14851
13575
|
provider.onDidChangeInlayHints = emitter.event;
|
|
14852
13576
|
}
|
|
14853
|
-
this._registrations.set(handle,
|
|
13577
|
+
this._registrations.set(handle, this._languageFeaturesService.inlayHintsProvider.register(selector, provider));
|
|
14854
13578
|
}
|
|
14855
13579
|
$emitInlayHintsEvent(eventHandle) {
|
|
14856
13580
|
const obj = this._registrations.get(eventHandle);
|
|
@@ -14887,11 +13611,11 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
14887
13611
|
});
|
|
14888
13612
|
};
|
|
14889
13613
|
}
|
|
14890
|
-
this._registrations.set(handle,
|
|
13614
|
+
this._registrations.set(handle, this._languageFeaturesService.linkProvider.register(selector, provider));
|
|
14891
13615
|
}
|
|
14892
13616
|
$registerDocumentColorProvider(handle, selector) {
|
|
14893
13617
|
const proxy = this._proxy;
|
|
14894
|
-
this._registrations.set(handle,
|
|
13618
|
+
this._registrations.set(handle, this._languageFeaturesService.colorProvider.register(selector, {
|
|
14895
13619
|
provideDocumentColors: (model, token) => {
|
|
14896
13620
|
return proxy.$provideDocumentColors(handle, model.uri, token)
|
|
14897
13621
|
.then(documentColors => {
|
|
@@ -14929,7 +13653,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
14929
13653
|
this._registrations.set(eventHandle, emitter);
|
|
14930
13654
|
provider.onDidChange = emitter.event;
|
|
14931
13655
|
}
|
|
14932
|
-
this._registrations.set(handle,
|
|
13656
|
+
this._registrations.set(handle, this._languageFeaturesService.foldingRangeProvider.register(selector, provider));
|
|
14933
13657
|
}
|
|
14934
13658
|
$emitFoldingRangeEvent(eventHandle, event) {
|
|
14935
13659
|
const obj = this._registrations.get(eventHandle);
|
|
@@ -14938,14 +13662,14 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
14938
13662
|
}
|
|
14939
13663
|
}
|
|
14940
13664
|
$registerSelectionRangeProvider(handle, selector) {
|
|
14941
|
-
this._registrations.set(handle,
|
|
13665
|
+
this._registrations.set(handle, this._languageFeaturesService.selectionRangeProvider.register(selector, {
|
|
14942
13666
|
provideSelectionRanges: (model, positions, token) => {
|
|
14943
13667
|
return this._proxy.$provideSelectionRanges(handle, model.uri, positions, token);
|
|
14944
13668
|
}
|
|
14945
13669
|
}));
|
|
14946
13670
|
}
|
|
14947
13671
|
$registerCallHierarchyProvider(handle, selector) {
|
|
14948
|
-
this._registrations.set(handle,
|
|
13672
|
+
this._registrations.set(handle, CallHierarchyProviderRegistry.register(selector, {
|
|
14949
13673
|
prepareCallHierarchy: async (document, position, token) => {
|
|
14950
13674
|
const items = await this._proxy.$prepareCallHierarchy(handle, document.uri, position, token);
|
|
14951
13675
|
if (!items || items.length === 0) {
|
|
@@ -15033,7 +13757,7 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
15033
13757
|
}
|
|
15034
13758
|
}
|
|
15035
13759
|
$registerTypeHierarchyProvider(handle, selector) {
|
|
15036
|
-
this._registrations.set(handle,
|
|
13760
|
+
this._registrations.set(handle, TypeHierarchyProviderRegistry.register(selector, {
|
|
15037
13761
|
prepareTypeHierarchy: async (document, position, token) => {
|
|
15038
13762
|
const items = await this._proxy.$prepareTypeHierarchy(handle, document.uri, position, token);
|
|
15039
13763
|
if (!items) {
|
|
@@ -15065,7 +13789,12 @@ let MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = class MainThread
|
|
|
15065
13789
|
}));
|
|
15066
13790
|
}
|
|
15067
13791
|
};
|
|
15068
|
-
MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 =
|
|
13792
|
+
MainThreadLanguageFeatures = MainThreadLanguageFeatures_1 = __decorate([
|
|
13793
|
+
extHostNamedCustomer(MainContext.MainThreadLanguageFeatures),
|
|
13794
|
+
__param(1, ILanguageService),
|
|
13795
|
+
__param(2, ILanguageConfigurationService),
|
|
13796
|
+
__param(3, ILanguageFeaturesService)
|
|
13797
|
+
], MainThreadLanguageFeatures);
|
|
15069
13798
|
class MainThreadDocumentSemanticTokensProvider {
|
|
15070
13799
|
constructor(_proxy, _handle, _legend, onDidChange) {
|
|
15071
13800
|
this._proxy = _proxy;
|
|
@@ -15130,7 +13859,7 @@ class MainThreadDocumentRangeSemanticTokensProvider {
|
|
|
15130
13859
|
throw new Error(`Unexpected`);
|
|
15131
13860
|
}
|
|
15132
13861
|
}
|
|
15133
|
-
const
|
|
13862
|
+
const DEFAULT_EXTENSION = {
|
|
15134
13863
|
identifier: new ExtensionIdentifier('monaco'),
|
|
15135
13864
|
isBuiltin: true,
|
|
15136
13865
|
isUserBuiltin: true,
|
|
@@ -15140,7 +13869,7 @@ const extension = {
|
|
|
15140
13869
|
publisher: 'microsoft',
|
|
15141
13870
|
version: '1.0.0',
|
|
15142
13871
|
engines: {
|
|
15143
|
-
vscode: "1.
|
|
13872
|
+
vscode: "1.67.0"
|
|
15144
13873
|
}
|
|
15145
13874
|
};
|
|
15146
13875
|
class SimpleMessagePassingProtocol {
|
|
@@ -15172,6 +13901,18 @@ class MonacoMainThreadDiagnostics extends MainThreadDiagnostics {
|
|
|
15172
13901
|
}
|
|
15173
13902
|
}
|
|
15174
13903
|
}
|
|
13904
|
+
class MainThreadMessageServiceWithoutSource extends MainThreadMessageService {
|
|
13905
|
+
constructor() {
|
|
13906
|
+
super(...arguments);
|
|
13907
|
+
this.$showMessage = (severity, message, options, commands) => {
|
|
13908
|
+
const _options = {
|
|
13909
|
+
...options,
|
|
13910
|
+
source: undefined
|
|
13911
|
+
};
|
|
13912
|
+
return super.$showMessage(severity, message, _options, commands);
|
|
13913
|
+
};
|
|
13914
|
+
}
|
|
13915
|
+
}
|
|
15175
13916
|
function createExtHostServices() {
|
|
15176
13917
|
const commandsService = StandaloneServices.get(ICommandService);
|
|
15177
13918
|
const notificationService = StandaloneServices.get(INotificationService);
|
|
@@ -15243,7 +13984,7 @@ function createExtHostServices() {
|
|
|
15243
13984
|
const extHostClipboard = new ExtHostClipboard(mainContext);
|
|
15244
13985
|
const extHostLanguageFeatures = rpcProtocol.set(ExtHostContext.ExtHostLanguageFeatures, new ExtHostLanguageFeatures(rpcProtocol, uriTransformerService, extHostDocuments, extHostCommands, extHostDiagnostics, extHostLogService, extHostApiDeprecationService));
|
|
15245
13986
|
rpcProtocol.set(ExtHostContext.ExtHostTelemetry, new ExtHostTelemetry());
|
|
15246
|
-
rpcProtocol.set(MainContext.MainThreadMessageService, new
|
|
13987
|
+
rpcProtocol.set(MainContext.MainThreadMessageService, new MainThreadMessageServiceWithoutSource(mainContext, notificationService, commandsService, dialogService));
|
|
15247
13988
|
rpcProtocol.set(MainContext.MainThreadDiagnostics, new MonacoMainThreadDiagnostics(mainContext, markerService, uriIdentityService));
|
|
15248
13989
|
rpcProtocol.set(MainContext.MainThreadQuickOpen, new MainThreadQuickOpen(mainContext, quickInputService));
|
|
15249
13990
|
rpcProtocol.set(MainContext.MainThreadTelemetry, new MainThreadTelemetry(mainContext, telemetryService, configurationService, workbenchEnvironmentService, productService));
|
|
@@ -15287,6 +14028,7 @@ function checkSelector(selector) {
|
|
|
15287
14028
|
const languages$1 = {
|
|
15288
14029
|
createDiagnosticCollection(name) {
|
|
15289
14030
|
const { extHostDiagnostics } = getExtHostServices();
|
|
14031
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15290
14032
|
return extHostDiagnostics.createDiagnosticCollection(extension.identifier, name);
|
|
15291
14033
|
},
|
|
15292
14034
|
get onDidChangeDiagnostics() {
|
|
@@ -15310,86 +14052,107 @@ const languages$1 = {
|
|
|
15310
14052
|
},
|
|
15311
14053
|
registerCodeActionsProvider(selector, provider, metadata) {
|
|
15312
14054
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14055
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15313
14056
|
return extHostLanguageFeatures.registerCodeActionProvider(extension, checkSelector(selector), provider, metadata);
|
|
15314
14057
|
},
|
|
15315
14058
|
registerCodeLensProvider(selector, provider) {
|
|
15316
14059
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14060
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15317
14061
|
return extHostLanguageFeatures.registerCodeLensProvider(extension, checkSelector(selector), provider);
|
|
15318
14062
|
},
|
|
15319
14063
|
registerDefinitionProvider(selector, provider) {
|
|
15320
14064
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14065
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15321
14066
|
return extHostLanguageFeatures.registerDefinitionProvider(extension, checkSelector(selector), provider);
|
|
15322
14067
|
},
|
|
15323
14068
|
registerDeclarationProvider(selector, provider) {
|
|
15324
14069
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14070
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15325
14071
|
return extHostLanguageFeatures.registerDeclarationProvider(extension, checkSelector(selector), provider);
|
|
15326
14072
|
},
|
|
15327
14073
|
registerImplementationProvider(selector, provider) {
|
|
15328
14074
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14075
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15329
14076
|
return extHostLanguageFeatures.registerImplementationProvider(extension, checkSelector(selector), provider);
|
|
15330
14077
|
},
|
|
15331
14078
|
registerTypeDefinitionProvider(selector, provider) {
|
|
15332
14079
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14080
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15333
14081
|
return extHostLanguageFeatures.registerTypeDefinitionProvider(extension, checkSelector(selector), provider);
|
|
15334
14082
|
},
|
|
15335
14083
|
registerHoverProvider(selector, provider) {
|
|
15336
14084
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14085
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15337
14086
|
return extHostLanguageFeatures.registerHoverProvider(extension, checkSelector(selector), provider, extension.identifier);
|
|
15338
14087
|
},
|
|
15339
14088
|
registerEvaluatableExpressionProvider(selector, provider) {
|
|
15340
14089
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14090
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15341
14091
|
return extHostLanguageFeatures.registerEvaluatableExpressionProvider(extension, checkSelector(selector), provider, extension.identifier);
|
|
15342
14092
|
},
|
|
15343
14093
|
registerInlineValuesProvider(selector, provider) {
|
|
15344
14094
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14095
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15345
14096
|
return extHostLanguageFeatures.registerInlineValuesProvider(extension, checkSelector(selector), provider, extension.identifier);
|
|
15346
14097
|
},
|
|
15347
14098
|
registerDocumentHighlightProvider(selector, provider) {
|
|
15348
14099
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14100
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15349
14101
|
return extHostLanguageFeatures.registerDocumentHighlightProvider(extension, checkSelector(selector), provider);
|
|
15350
14102
|
},
|
|
15351
14103
|
registerLinkedEditingRangeProvider(selector, provider) {
|
|
15352
14104
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14105
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15353
14106
|
return extHostLanguageFeatures.registerLinkedEditingRangeProvider(extension, checkSelector(selector), provider);
|
|
15354
14107
|
},
|
|
15355
14108
|
registerReferenceProvider(selector, provider) {
|
|
15356
14109
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14110
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15357
14111
|
return extHostLanguageFeatures.registerReferenceProvider(extension, checkSelector(selector), provider);
|
|
15358
14112
|
},
|
|
15359
14113
|
registerRenameProvider(selector, provider) {
|
|
15360
14114
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14115
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15361
14116
|
return extHostLanguageFeatures.registerRenameProvider(extension, checkSelector(selector), provider);
|
|
15362
14117
|
},
|
|
15363
14118
|
registerDocumentSymbolProvider(selector, provider, metadata) {
|
|
15364
14119
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14120
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15365
14121
|
return extHostLanguageFeatures.registerDocumentSymbolProvider(extension, checkSelector(selector), provider, metadata);
|
|
15366
14122
|
},
|
|
15367
14123
|
registerWorkspaceSymbolProvider(provider) {
|
|
15368
14124
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14125
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15369
14126
|
return extHostLanguageFeatures.registerWorkspaceSymbolProvider(extension, provider);
|
|
15370
14127
|
},
|
|
15371
14128
|
registerDocumentFormattingEditProvider(selector, provider) {
|
|
15372
14129
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14130
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15373
14131
|
return extHostLanguageFeatures.registerDocumentFormattingEditProvider(extension, checkSelector(selector), provider);
|
|
15374
14132
|
},
|
|
15375
14133
|
registerDocumentRangeFormattingEditProvider(selector, provider) {
|
|
15376
14134
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14135
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15377
14136
|
return extHostLanguageFeatures.registerDocumentRangeFormattingEditProvider(extension, checkSelector(selector), provider);
|
|
15378
14137
|
},
|
|
15379
14138
|
registerOnTypeFormattingEditProvider(selector, provider, firstTriggerCharacter, ...moreTriggerCharacters) {
|
|
15380
14139
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14140
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15381
14141
|
return extHostLanguageFeatures.registerOnTypeFormattingEditProvider(extension, checkSelector(selector), provider, [firstTriggerCharacter].concat(moreTriggerCharacters));
|
|
15382
14142
|
},
|
|
15383
14143
|
registerDocumentSemanticTokensProvider(selector, provider, legend) {
|
|
15384
14144
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14145
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15385
14146
|
return extHostLanguageFeatures.registerDocumentSemanticTokensProvider(extension, checkSelector(selector), provider, legend);
|
|
15386
14147
|
},
|
|
15387
14148
|
registerDocumentRangeSemanticTokensProvider(selector, provider, legend) {
|
|
15388
14149
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14150
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15389
14151
|
return extHostLanguageFeatures.registerDocumentRangeSemanticTokensProvider(extension, checkSelector(selector), provider, legend);
|
|
15390
14152
|
},
|
|
15391
14153
|
registerSignatureHelpProvider(selector, provider, firstItem, ...remaining) {
|
|
15392
14154
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14155
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15393
14156
|
if (typeof firstItem === 'object') {
|
|
15394
14157
|
return extHostLanguageFeatures.registerSignatureHelpProvider(extension, checkSelector(selector), provider, firstItem);
|
|
15395
14158
|
}
|
|
@@ -15397,53 +14160,59 @@ const languages$1 = {
|
|
|
15397
14160
|
},
|
|
15398
14161
|
registerCompletionItemProvider(selector, provider, ...triggerCharacters) {
|
|
15399
14162
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14163
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15400
14164
|
return extHostLanguageFeatures.registerCompletionItemProvider(extension, checkSelector(selector), provider, triggerCharacters);
|
|
15401
14165
|
},
|
|
15402
|
-
registerInlineCompletionItemProvider(selector, provider) {
|
|
15403
|
-
const { extHostLanguageFeatures } = getExtHostServices();
|
|
15404
|
-
return extHostLanguageFeatures.registerInlineCompletionsProvider(extension, checkSelector(selector), provider);
|
|
15405
|
-
},
|
|
15406
14166
|
registerDocumentLinkProvider(selector, provider) {
|
|
15407
14167
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14168
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15408
14169
|
return extHostLanguageFeatures.registerDocumentLinkProvider(extension, checkSelector(selector), provider);
|
|
15409
14170
|
},
|
|
15410
14171
|
registerColorProvider(selector, provider) {
|
|
15411
14172
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14173
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15412
14174
|
return extHostLanguageFeatures.registerColorProvider(extension, checkSelector(selector), provider);
|
|
15413
14175
|
},
|
|
15414
14176
|
registerFoldingRangeProvider(selector, provider) {
|
|
15415
14177
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14178
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15416
14179
|
return extHostLanguageFeatures.registerFoldingRangeProvider(extension, checkSelector(selector), provider);
|
|
15417
14180
|
},
|
|
15418
14181
|
registerSelectionRangeProvider(selector, provider) {
|
|
15419
14182
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14183
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15420
14184
|
return extHostLanguageFeatures.registerSelectionRangeProvider(extension, selector, provider);
|
|
15421
14185
|
},
|
|
15422
14186
|
registerCallHierarchyProvider(selector, provider) {
|
|
15423
14187
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14188
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15424
14189
|
return extHostLanguageFeatures.registerCallHierarchyProvider(extension, selector, provider);
|
|
15425
14190
|
},
|
|
15426
14191
|
registerTypeHierarchyProvider(selector, provider) {
|
|
15427
14192
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14193
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15428
14194
|
return extHostLanguageFeatures.registerTypeHierarchyProvider(extension, selector, provider);
|
|
15429
14195
|
},
|
|
15430
14196
|
setLanguageConfiguration: (language, configuration) => {
|
|
15431
14197
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14198
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15432
14199
|
return extHostLanguageFeatures.setLanguageConfiguration(extension, language, configuration);
|
|
15433
14200
|
},
|
|
15434
14201
|
registerInlayHintsProvider(selector, provider) {
|
|
15435
14202
|
const { extHostLanguageFeatures } = getExtHostServices();
|
|
14203
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15436
14204
|
return extHostLanguageFeatures.registerInlayHintsProvider(extension, selector, provider);
|
|
15437
14205
|
},
|
|
15438
14206
|
createLanguageStatusItem(id, selector) {
|
|
15439
14207
|
const { extHostLanguages } = getExtHostServices();
|
|
14208
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15440
14209
|
return extHostLanguages.createLanguageStatusItem(extension, id, selector);
|
|
15441
14210
|
}
|
|
15442
14211
|
};
|
|
15443
14212
|
const commands$1 = {
|
|
15444
14213
|
registerCommand(id, command, thisArgs) {
|
|
15445
14214
|
const { extHostCommands } = getExtHostServices();
|
|
15446
|
-
return extHostCommands.registerCommand(true, id, command, thisArgs, undefined, extension);
|
|
14215
|
+
return extHostCommands.registerCommand(true, id, command, thisArgs, undefined, Services.get().extension ?? DEFAULT_EXTENSION);
|
|
15447
14216
|
},
|
|
15448
14217
|
registerTextEditorCommand(id, callback, thisArg) {
|
|
15449
14218
|
const { extHostCommands, extHostEditors, extHostLogService } = getExtHostServices();
|
|
@@ -15462,7 +14231,7 @@ const commands$1 = {
|
|
|
15462
14231
|
}, (err) => {
|
|
15463
14232
|
extHostLogService.warn('An error occurred while running command ' + id, err);
|
|
15464
14233
|
});
|
|
15465
|
-
}, undefined, undefined, extension);
|
|
14234
|
+
}, undefined, undefined, Services.get().extension ?? DEFAULT_EXTENSION);
|
|
15466
14235
|
},
|
|
15467
14236
|
executeCommand(id, ...args) {
|
|
15468
14237
|
const { extHostCommands } = getExtHostServices();
|
|
@@ -15672,15 +14441,15 @@ const workspace$1 = {
|
|
|
15672
14441
|
const window$2 = {
|
|
15673
14442
|
showInformationMessage(message, ...rest) {
|
|
15674
14443
|
const { extHostMessageService } = getExtHostServices();
|
|
15675
|
-
return extHostMessageService.showMessage(extension, Severity.Info, message, rest[0], rest.slice(1));
|
|
14444
|
+
return extHostMessageService.showMessage(Services.get().extension ?? DEFAULT_EXTENSION, Severity.Info, message, rest[0], rest.slice(1));
|
|
15676
14445
|
},
|
|
15677
14446
|
showWarningMessage(message, ...rest) {
|
|
15678
14447
|
const { extHostMessageService } = getExtHostServices();
|
|
15679
|
-
return extHostMessageService.showMessage(extension, Severity.Warning, message, rest[0], rest.slice(1));
|
|
14448
|
+
return extHostMessageService.showMessage(Services.get().extension ?? DEFAULT_EXTENSION, Severity.Warning, message, rest[0], rest.slice(1));
|
|
15680
14449
|
},
|
|
15681
14450
|
showErrorMessage(message, ...rest) {
|
|
15682
14451
|
const { extHostMessageService } = getExtHostServices();
|
|
15683
|
-
return extHostMessageService.showMessage(extension, Severity.Error, message, rest[0], rest.slice(1));
|
|
14452
|
+
return extHostMessageService.showMessage(Services.get().extension ?? DEFAULT_EXTENSION, Severity.Error, message, rest[0], rest.slice(1));
|
|
15684
14453
|
},
|
|
15685
14454
|
createOutputChannel(name) {
|
|
15686
14455
|
const { window } = Services.get();
|
|
@@ -15699,11 +14468,11 @@ const window$2 = {
|
|
|
15699
14468
|
},
|
|
15700
14469
|
withScmProgress(task) {
|
|
15701
14470
|
const { extHostProgress } = getExtHostServices();
|
|
15702
|
-
return extHostProgress.withProgress(extension, { location: ProgressLocation$2.SourceControl }, () => task({ report() { } }));
|
|
14471
|
+
return extHostProgress.withProgress(Services.get().extension ?? DEFAULT_EXTENSION, { location: ProgressLocation$2.SourceControl }, () => task({ report() { } }));
|
|
15703
14472
|
},
|
|
15704
14473
|
withProgress(options, task) {
|
|
15705
14474
|
const { extHostProgress } = getExtHostServices();
|
|
15706
|
-
return extHostProgress.withProgress(extension, options, task);
|
|
14475
|
+
return extHostProgress.withProgress(Services.get().extension ?? DEFAULT_EXTENSION, options, task);
|
|
15707
14476
|
},
|
|
15708
14477
|
showTextDocument: async (documentOrUri, columnOrOptions, preserveFocus) => {
|
|
15709
14478
|
const { extHostEditors } = getExtHostServices();
|
|
@@ -15714,7 +14483,7 @@ const window$2 = {
|
|
|
15714
14483
|
},
|
|
15715
14484
|
createQuickPick() {
|
|
15716
14485
|
const { extHostQuickOpen } = getExtHostServices();
|
|
15717
|
-
return extHostQuickOpen.createQuickPick(extension);
|
|
14486
|
+
return extHostQuickOpen.createQuickPick(Services.get().extension ?? DEFAULT_EXTENSION);
|
|
15718
14487
|
},
|
|
15719
14488
|
showQuickPick(items, options, token) {
|
|
15720
14489
|
const { extHostQuickOpen } = getExtHostServices();
|
|
@@ -15722,6 +14491,7 @@ const window$2 = {
|
|
|
15722
14491
|
},
|
|
15723
14492
|
createInputBox() {
|
|
15724
14493
|
const { extHostQuickOpen } = getExtHostServices();
|
|
14494
|
+
const extension = Services.get().extension ?? DEFAULT_EXTENSION;
|
|
15725
14495
|
return extHostQuickOpen.createInputBox(extension.identifier);
|
|
15726
14496
|
},
|
|
15727
14497
|
showInputBox(options, token) {
|
|
@@ -15797,14 +14567,7 @@ const window$2 = {
|
|
|
15797
14567
|
onDidChangeTerminalState: Event.None,
|
|
15798
14568
|
get tabGroups() {
|
|
15799
14569
|
return unsupported$1();
|
|
15800
|
-
}
|
|
15801
|
-
showNotebookDocument: unsupported$1,
|
|
15802
|
-
visibleNotebookEditors: [],
|
|
15803
|
-
onDidChangeVisibleNotebookEditors: Event.None,
|
|
15804
|
-
activeNotebookEditor: undefined,
|
|
15805
|
-
onDidChangeActiveNotebookEditor: Event.None,
|
|
15806
|
-
onDidChangeNotebookEditorSelection: Event.None,
|
|
15807
|
-
onDidChangeNotebookEditorVisibleRanges: Event.None
|
|
14570
|
+
}
|
|
15808
14571
|
};
|
|
15809
14572
|
const env$1 = {
|
|
15810
14573
|
appName: 'Monaco',
|
|
@@ -15852,7 +14615,7 @@ const env$1 = {
|
|
|
15852
14615
|
};
|
|
15853
14616
|
const unsupported = undefined;
|
|
15854
14617
|
const api = {
|
|
15855
|
-
version:
|
|
14618
|
+
version: "1.67.0",
|
|
15856
14619
|
tasks: unsupported,
|
|
15857
14620
|
notebooks: unsupported,
|
|
15858
14621
|
scm: unsupported,
|
|
@@ -16003,12 +14766,7 @@ const api = {
|
|
|
16003
14766
|
TabInputNotebook: unsupported,
|
|
16004
14767
|
TabInputNotebookDiff: unsupported,
|
|
16005
14768
|
TabInputWebview: unsupported,
|
|
16006
|
-
TabInputTerminal: unsupported
|
|
16007
|
-
InputBoxValidationSeverity: unsupported,
|
|
16008
|
-
InlineCompletionList: unsupported,
|
|
16009
|
-
InlineCompletionTriggerKind: unsupported,
|
|
16010
|
-
InlineCompletionItem: unsupported,
|
|
16011
|
-
NotebookEditorRevealType: NotebookEditorRevealType$1
|
|
14769
|
+
TabInputTerminal: unsupported
|
|
16012
14770
|
};
|
|
16013
|
-
const { version, tasks, notebooks, scm, debug, extensions, comments, authentication, tests, env, commands, window: window$1, workspace, languages, Breakpoint, CallHierarchyIncomingCall, CallHierarchyItem, CallHierarchyOutgoingCall, CancellationError, CancellationTokenSource, CodeAction, CodeActionKind, CodeActionTriggerKind, CodeLens, Color, ColorInformation, ColorPresentation, ColorThemeKind, CommentMode, CommentThreadCollapsibleState, CompletionItem, CompletionItemKind, CompletionItemTag, CompletionList, CompletionTriggerKind, ConfigurationTarget, CustomExecution, DebugAdapterExecutable, DebugAdapterInlineImplementation, DebugAdapterNamedPipeServer, DebugAdapterServer, DebugConfigurationProviderTriggerKind, DebugConsoleMode, DecorationRangeBehavior, Diagnostic, DiagnosticRelatedInformation, DiagnosticSeverity, DiagnosticTag, Disposable, DocumentHighlight, DocumentHighlightKind, DocumentLink, DocumentSymbol, EndOfLine, EnvironmentVariableMutatorType, EvaluatableExpression, InlineValueText, InlineValueVariableLookup, InlineValueEvaluatableExpression, EventEmitter, ExtensionKind, ExtensionMode, FileChangeType, FileDecoration, FileSystemError, FileType, FilePermission, FoldingRange, FoldingRangeKind, FunctionBreakpoint, Hover, IndentAction, Location, MarkdownString, OverviewRulerLane, ParameterInformation, Position, ProcessExecution, ProgressLocation, QuickInputButtons, Range, RelativePattern, Selection, SelectionRange, SemanticTokens, SemanticTokensBuilder, SemanticTokensEdit, SemanticTokensEdits, SemanticTokensLegend, ShellExecution, ShellQuoting, SignatureHelp, SignatureHelpTriggerKind, SignatureInformation, SnippetString, SourceBreakpoint, StatusBarAlignment, SymbolInformation, SymbolKind, SymbolTag, Task, TaskGroup, TaskPanelKind, TaskRevealKind, TaskScope, TerminalLink, TerminalLocation, TerminalProfile, TextDocumentSaveReason, TextEdit, TextEditorCursorStyle, TextEditorLineNumbersStyle, TextEditorRevealType, TextEditorSelectionChangeKind, TextDocumentChangeReason, ThemeColor, ThemeIcon, TreeItem, TreeItemCollapsibleState, TypeHierarchyItem, UIKind, Uri, ViewColumn, WorkspaceEdit, InlayHint, InlayHintLabelPart, InlayHintKind, NotebookRange, NotebookCellKind, NotebookCellData, NotebookData, NotebookCellStatusBarAlignment, NotebookCellOutput, NotebookCellOutputItem, NotebookCellStatusBarItem, NotebookControllerAffinity, LinkedEditingRanges, TestRunRequest, TestMessage, TestTag, TestRunProfileKind, DataTransfer, DataTransferItem, LanguageStatusSeverity, QuickPickItemKind, TabInputText, TabInputTextDiff, TabInputCustom, TabInputNotebook, TabInputNotebookDiff, TabInputWebview, TabInputTerminal
|
|
16014
|
-
export { Breakpoint, CallHierarchyIncomingCall, CallHierarchyItem, CallHierarchyOutgoingCall, CancellationError, CancellationTokenSource, CodeAction, CodeActionKind, CodeActionTriggerKind, CodeLens, Color, ColorInformation, ColorPresentation, ColorThemeKind, CommentMode, CommentThreadCollapsibleState, CompletionItem, CompletionItemKind, CompletionItemTag, CompletionList, CompletionTriggerKind, ConfigurationTarget, CustomExecution, DataTransfer, DataTransferItem, DebugAdapterExecutable, DebugAdapterInlineImplementation, DebugAdapterNamedPipeServer, DebugAdapterServer, DebugConfigurationProviderTriggerKind, DebugConsoleMode, DecorationRangeBehavior, Diagnostic, DiagnosticRelatedInformation, DiagnosticSeverity, DiagnosticTag, Disposable, DocumentHighlight, DocumentHighlightKind, DocumentLink, DocumentSymbol, EndOfLine, EnvironmentVariableMutatorType, EvaluatableExpression, EventEmitter, ExtensionKind, ExtensionMode, FileChangeType, FileDecoration, FilePermission, FileSystemError, FileType, FoldingRange, FoldingRangeKind, FunctionBreakpoint, Hover, IndentAction, InlayHint, InlayHintKind, InlayHintLabelPart,
|
|
14771
|
+
const { version, tasks, notebooks, scm, debug, extensions, comments, authentication, tests, env, commands, window: window$1, workspace, languages, Breakpoint, CallHierarchyIncomingCall, CallHierarchyItem, CallHierarchyOutgoingCall, CancellationError, CancellationTokenSource, CodeAction, CodeActionKind, CodeActionTriggerKind, CodeLens, Color, ColorInformation, ColorPresentation, ColorThemeKind, CommentMode, CommentThreadCollapsibleState, CompletionItem, CompletionItemKind, CompletionItemTag, CompletionList, CompletionTriggerKind, ConfigurationTarget, CustomExecution, DebugAdapterExecutable, DebugAdapterInlineImplementation, DebugAdapterNamedPipeServer, DebugAdapterServer, DebugConfigurationProviderTriggerKind, DebugConsoleMode, DecorationRangeBehavior, Diagnostic, DiagnosticRelatedInformation, DiagnosticSeverity, DiagnosticTag, Disposable, DocumentHighlight, DocumentHighlightKind, DocumentLink, DocumentSymbol, EndOfLine, EnvironmentVariableMutatorType, EvaluatableExpression, InlineValueText, InlineValueVariableLookup, InlineValueEvaluatableExpression, EventEmitter, ExtensionKind, ExtensionMode, FileChangeType, FileDecoration, FileSystemError, FileType, FilePermission, FoldingRange, FoldingRangeKind, FunctionBreakpoint, Hover, IndentAction, Location, MarkdownString, OverviewRulerLane, ParameterInformation, Position, ProcessExecution, ProgressLocation, QuickInputButtons, Range, RelativePattern, Selection, SelectionRange, SemanticTokens, SemanticTokensBuilder, SemanticTokensEdit, SemanticTokensEdits, SemanticTokensLegend, ShellExecution, ShellQuoting, SignatureHelp, SignatureHelpTriggerKind, SignatureInformation, SnippetString, SourceBreakpoint, StatusBarAlignment, SymbolInformation, SymbolKind, SymbolTag, Task, TaskGroup, TaskPanelKind, TaskRevealKind, TaskScope, TerminalLink, TerminalLocation, TerminalProfile, TextDocumentSaveReason, TextEdit, TextEditorCursorStyle, TextEditorLineNumbersStyle, TextEditorRevealType, TextEditorSelectionChangeKind, TextDocumentChangeReason, ThemeColor, ThemeIcon, TreeItem, TreeItemCollapsibleState, TypeHierarchyItem, UIKind, Uri, ViewColumn, WorkspaceEdit, InlayHint, InlayHintLabelPart, InlayHintKind, NotebookRange, NotebookCellKind, NotebookCellData, NotebookData, NotebookCellStatusBarAlignment, NotebookCellOutput, NotebookCellOutputItem, NotebookCellStatusBarItem, NotebookControllerAffinity, LinkedEditingRanges, TestRunRequest, TestMessage, TestTag, TestRunProfileKind, DataTransfer, DataTransferItem, LanguageStatusSeverity, QuickPickItemKind, TabInputText, TabInputTextDiff, TabInputCustom, TabInputNotebook, TabInputNotebookDiff, TabInputWebview, TabInputTerminal } = api;
|
|
14772
|
+
export { Breakpoint, CallHierarchyIncomingCall, CallHierarchyItem, CallHierarchyOutgoingCall, CancellationError, CancellationTokenSource, CodeAction, CodeActionKind, CodeActionTriggerKind, CodeLens, Color, ColorInformation, ColorPresentation, ColorThemeKind, CommentMode, CommentThreadCollapsibleState, CompletionItem, CompletionItemKind, CompletionItemTag, CompletionList, CompletionTriggerKind, ConfigurationTarget, CustomExecution, DataTransfer, DataTransferItem, DebugAdapterExecutable, DebugAdapterInlineImplementation, DebugAdapterNamedPipeServer, DebugAdapterServer, DebugConfigurationProviderTriggerKind, DebugConsoleMode, DecorationRangeBehavior, Diagnostic, DiagnosticRelatedInformation, DiagnosticSeverity, DiagnosticTag, Disposable, DocumentHighlight, DocumentHighlightKind, DocumentLink, DocumentSymbol, EndOfLine, EnvironmentVariableMutatorType, EvaluatableExpression, EventEmitter, ExtensionKind, ExtensionMode, FileChangeType, FileDecoration, FilePermission, FileSystemError, FileType, FoldingRange, FoldingRangeKind, FunctionBreakpoint, Hover, IndentAction, InlayHint, InlayHintKind, InlayHintLabelPart, InlineValueEvaluatableExpression, InlineValueText, InlineValueVariableLookup, LanguageStatusSeverity, LinkedEditingRanges, Location, MarkdownString, NotebookCellData, NotebookCellKind, NotebookCellOutput, NotebookCellOutputItem, NotebookCellStatusBarAlignment, NotebookCellStatusBarItem, NotebookControllerAffinity, NotebookData, NotebookRange, OverviewRulerLane, ParameterInformation, Position, ProcessExecution, ProgressLocation, QuickInputButtons, QuickPickItemKind, Range, RelativePattern, Selection, SelectionRange, SemanticTokens, SemanticTokensBuilder, SemanticTokensEdit, SemanticTokensEdits, SemanticTokensLegend, ShellExecution, ShellQuoting, SignatureHelp, SignatureHelpTriggerKind, SignatureInformation, SnippetString, SourceBreakpoint, StatusBarAlignment, SymbolInformation, SymbolKind, SymbolTag, TabInputCustom, TabInputNotebook, TabInputNotebookDiff, TabInputTerminal, TabInputText, TabInputTextDiff, TabInputWebview, Task, TaskGroup, TaskPanelKind, TaskRevealKind, TaskScope, TerminalLink, TerminalLocation, TerminalProfile, TestMessage, TestRunProfileKind, TestRunRequest, TestTag, TextDocumentChangeReason, TextDocumentSaveReason, TextEdit, TextEditorCursorStyle, TextEditorLineNumbersStyle, TextEditorRevealType, TextEditorSelectionChangeKind, ThemeColor, ThemeIcon, TreeItem, TreeItemCollapsibleState, TypeHierarchyItem, UIKind, Uri, ViewColumn, WorkspaceEdit, authentication, commands, comments, debug, env, extensions, languages, notebooks, scm, tasks, tests, version, window$1 as window, workspace };
|