@codingame/monaco-vscode-extensions-service-override 4.0.0 → 4.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/extensions.js +6 -6
- package/package.json +9 -9
- package/_virtual/semver.js +0 -3
- package/external/vscode-semver/semver.js +0 -985
- package/override/vs/workbench/browser/parts/editor/textEditor.weak.js +0 -8
- package/vscode/src/vs/base/common/console.js +0 -62
- package/vscode/src/vs/platform/extensionManagement/common/extensionManagementCLI.js +0 -497
- package/vscode/src/vs/platform/extensionResourceLoader/browser/extensionResourceLoaderService.js +0 -44
- package/vscode/src/vs/platform/lifecycle/common/lifecycle.js +0 -27
- package/vscode/src/vs/platform/remote/common/managedSocket.js +0 -98
- package/vscode/src/vs/workbench/api/browser/extensionHost.contribution.js +0 -104
- package/vscode/src/vs/workbench/api/browser/mainThreadAiEmbeddingVector.js +0 -31
- package/vscode/src/vs/workbench/api/browser/mainThreadAiRelatedInformation.js +0 -35
- package/vscode/src/vs/workbench/api/browser/mainThreadAuthentication.js +0 -254
- package/vscode/src/vs/workbench/api/browser/mainThreadBulkEdits.js +0 -68
- package/vscode/src/vs/workbench/api/browser/mainThreadCLICommands.js +0 -103
- package/vscode/src/vs/workbench/api/browser/mainThreadChat.js +0 -70
- package/vscode/src/vs/workbench/api/browser/mainThreadChatAgents2.js +0 -207
- package/vscode/src/vs/workbench/api/browser/mainThreadChatVariables.js +0 -41
- package/vscode/src/vs/workbench/api/browser/mainThreadClipboard.js +0 -24
- package/vscode/src/vs/workbench/api/browser/mainThreadCodeInsets.js +0 -108
- package/vscode/src/vs/workbench/api/browser/mainThreadCommands.js +0 -98
- package/vscode/src/vs/workbench/api/browser/mainThreadComments.js +0 -560
- package/vscode/src/vs/workbench/api/browser/mainThreadConfiguration.js +0 -80
- package/vscode/src/vs/workbench/api/browser/mainThreadConsole.js +0 -35
- package/vscode/src/vs/workbench/api/browser/mainThreadCustomEditors.js +0 -579
- package/vscode/src/vs/workbench/api/browser/mainThreadDebugService.js +0 -435
- package/vscode/src/vs/workbench/api/browser/mainThreadDecorations.js +0 -102
- package/vscode/src/vs/workbench/api/browser/mainThreadDiagnostics.js +0 -69
- package/vscode/src/vs/workbench/api/browser/mainThreadDialogs.js +0 -68
- package/vscode/src/vs/workbench/api/browser/mainThreadDocumentContentProviders.js +0 -79
- package/vscode/src/vs/workbench/api/browser/mainThreadDocuments.js +0 -253
- package/vscode/src/vs/workbench/api/browser/mainThreadDocumentsAndEditors.js +0 -370
- package/vscode/src/vs/workbench/api/browser/mainThreadDownloadService.js +0 -22
- package/vscode/src/vs/workbench/api/browser/mainThreadEditSessionIdentityParticipant.js +0 -41
- package/vscode/src/vs/workbench/api/browser/mainThreadEditor.js +0 -414
- package/vscode/src/vs/workbench/api/browser/mainThreadEditorTabs.js +0 -501
- package/vscode/src/vs/workbench/api/browser/mainThreadEditors.js +0 -227
- package/vscode/src/vs/workbench/api/browser/mainThreadErrors.js +0 -24
- package/vscode/src/vs/workbench/api/browser/mainThreadExtensionService.js +0 -317
- package/vscode/src/vs/workbench/api/browser/mainThreadFileSystem.js +0 -208
- package/vscode/src/vs/workbench/api/browser/mainThreadFileSystemEventService.js +0 -369
- package/vscode/src/vs/workbench/api/browser/mainThreadInlineChat.js +0 -72
- package/vscode/src/vs/workbench/api/browser/mainThreadInteractive.js +0 -28
- package/vscode/src/vs/workbench/api/browser/mainThreadIssueReporter.js +0 -50
- package/vscode/src/vs/workbench/api/browser/mainThreadLabelService.js +0 -27
- package/vscode/src/vs/workbench/api/browser/mainThreadLanguageFeatures.js +0 -1016
- package/vscode/src/vs/workbench/api/browser/mainThreadLanguageModels.js +0 -185
- package/vscode/src/vs/workbench/api/browser/mainThreadLanguages.js +0 -78
- package/vscode/src/vs/workbench/api/browser/mainThreadLocalization.js +0 -35
- package/vscode/src/vs/workbench/api/browser/mainThreadLogService.js +0 -78
- package/vscode/src/vs/workbench/api/browser/mainThreadManagedSockets.js +0 -93
- package/vscode/src/vs/workbench/api/browser/mainThreadMessageService.js +0 -137
- package/vscode/src/vs/workbench/api/browser/mainThreadNotebook.js +0 -194
- package/vscode/src/vs/workbench/api/browser/mainThreadNotebookDocuments.js +0 -123
- package/vscode/src/vs/workbench/api/browser/mainThreadNotebookDocumentsAndEditors.js +0 -188
- package/vscode/src/vs/workbench/api/browser/mainThreadNotebookDto.js +0 -129
- package/vscode/src/vs/workbench/api/browser/mainThreadNotebookEditors.js +0 -131
- package/vscode/src/vs/workbench/api/browser/mainThreadNotebookKernels.js +0 -374
- package/vscode/src/vs/workbench/api/browser/mainThreadNotebookRenderers.js +0 -25
- package/vscode/src/vs/workbench/api/browser/mainThreadNotebookSaveParticipant.js +0 -48
- package/vscode/src/vs/workbench/api/browser/mainThreadOutputService.js +0 -76
- package/vscode/src/vs/workbench/api/browser/mainThreadProfileContentHandlers.js +0 -38
- package/vscode/src/vs/workbench/api/browser/mainThreadProgress.js +0 -68
- package/vscode/src/vs/workbench/api/browser/mainThreadQuickDiff.js +0 -42
- package/vscode/src/vs/workbench/api/browser/mainThreadQuickOpen.js +0 -185
- package/vscode/src/vs/workbench/api/browser/mainThreadRemoteConnectionData.js +0 -30
- package/vscode/src/vs/workbench/api/browser/mainThreadSCM.js +0 -493
- package/vscode/src/vs/workbench/api/browser/mainThreadSaveParticipant.js +0 -49
- package/vscode/src/vs/workbench/api/browser/mainThreadSearch.js +0 -168
- package/vscode/src/vs/workbench/api/browser/mainThreadSecretState.js +0 -70
- package/vscode/src/vs/workbench/api/browser/mainThreadShare.js +0 -50
- package/vscode/src/vs/workbench/api/browser/mainThreadSpeech.js +0 -99
- package/vscode/src/vs/workbench/api/browser/mainThreadStatusBar.js +0 -53
- package/vscode/src/vs/workbench/api/browser/mainThreadStorage.js +0 -72
- package/vscode/src/vs/workbench/api/browser/mainThreadTask.js +0 -731
- package/vscode/src/vs/workbench/api/browser/mainThreadTelemetry.js +0 -53
- package/vscode/src/vs/workbench/api/browser/mainThreadTerminalService.js +0 -409
- package/vscode/src/vs/workbench/api/browser/mainThreadTerminalShellIntegration.js +0 -51
- package/vscode/src/vs/workbench/api/browser/mainThreadTesting.js +0 -219
- package/vscode/src/vs/workbench/api/browser/mainThreadTheming.js +0 -24
- package/vscode/src/vs/workbench/api/browser/mainThreadTimeline.js +0 -55
- package/vscode/src/vs/workbench/api/browser/mainThreadTreeViews.js +0 -312
- package/vscode/src/vs/workbench/api/browser/mainThreadTunnelService.js +0 -223
- package/vscode/src/vs/workbench/api/browser/mainThreadUriOpeners.js +0 -110
- package/vscode/src/vs/workbench/api/browser/mainThreadUrls.js +0 -61
- package/vscode/src/vs/workbench/api/browser/mainThreadWebviewManager.js +0 -29
- package/vscode/src/vs/workbench/api/browser/mainThreadWebviewPanels.js +0 -283
- package/vscode/src/vs/workbench/api/browser/mainThreadWebviewViews.js +0 -100
- package/vscode/src/vs/workbench/api/browser/mainThreadWebviews.js +0 -135
- package/vscode/src/vs/workbench/api/browser/mainThreadWindow.js +0 -57
- package/vscode/src/vs/workbench/api/browser/mainThreadWorkspace.js +0 -268
- package/vscode/src/vs/workbench/api/common/shared/dataTransferCache.js +0 -35
- package/vscode/src/vs/workbench/contrib/customEditor/common/customTextEditorModel.js +0 -76
- package/vscode/src/vs/workbench/contrib/externalUriOpener/common/contributedOpeners.js +0 -83
- package/vscode/src/vs/workbench/services/extensions/browser/extensionService.js +0 -285
- package/vscode/src/vs/workbench/services/extensions/browser/webWorkerExtensionHost.js +0 -276
- package/vscode/src/vs/workbench/services/extensions/browser/webWorkerFileSystemProvider.js +0 -52
- package/vscode/src/vs/workbench/services/extensions/common/abstractExtensionService.js +0 -1149
- package/vscode/src/vs/workbench/services/extensions/common/extHostCustomers.js +0 -41
- package/vscode/src/vs/workbench/services/extensions/common/extensionDevOptions.js +0 -25
- package/vscode/src/vs/workbench/services/extensions/common/extensionHostManager.js +0 -512
- package/vscode/src/vs/workbench/services/extensions/common/extensionRunningLocationTracker.js +0 -274
- package/vscode/src/vs/workbench/services/extensions/common/extensionStorageMigration.js +0 -58
- package/vscode/src/vs/workbench/services/extensions/common/extensionsProposedApi.js +0 -80
- package/vscode/src/vs/workbench/services/extensions/common/extensionsUtil.js +0 -64
- package/vscode/src/vs/workbench/services/extensions/common/lazyCreateExtensionHostManager.js +0 -161
- package/vscode/src/vs/workbench/services/extensions/common/remoteConsoleUtil.js +0 -49
- package/vscode/src/vs/workbench/services/extensions/common/remoteExtensionHost.js +0 -222
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
import { __decorate, __param } from '../../../../../../external/tslib/tslib.es6.js';
|
|
2
|
-
import { Disposable, DisposableMap } from 'vscode/vscode/vs/base/common/lifecycle';
|
|
3
|
-
import { revive } from 'vscode/vscode/vs/base/common/marshalling';
|
|
4
|
-
import { MainContext, ExtHostContext } from 'vscode/vscode/vs/workbench/api/common/extHost.protocol';
|
|
5
|
-
import { extHostNamedCustomer } from '../../services/extensions/common/extHostCustomers.js';
|
|
6
|
-
import { IUserDataProfileImportExportService } from 'vscode/vscode/vs/workbench/services/userDataProfile/common/userDataProfile';
|
|
7
|
-
|
|
8
|
-
let MainThreadProfileContentHandlers = class MainThreadProfileContentHandlers extends Disposable {
|
|
9
|
-
constructor(context, userDataProfileImportExportService) {
|
|
10
|
-
super();
|
|
11
|
-
this.userDataProfileImportExportService = userDataProfileImportExportService;
|
|
12
|
-
this.registeredHandlers = this._register(( new DisposableMap()));
|
|
13
|
-
this.proxy = ( context.getProxy(ExtHostContext.ExtHostProfileContentHandlers));
|
|
14
|
-
}
|
|
15
|
-
async $registerProfileContentHandler(id, name, description, extensionId) {
|
|
16
|
-
this.registeredHandlers.set(id, this.userDataProfileImportExportService.registerProfileContentHandler(id, {
|
|
17
|
-
name,
|
|
18
|
-
description,
|
|
19
|
-
extensionId,
|
|
20
|
-
saveProfile: async (name, content, token) => {
|
|
21
|
-
const result = await this.proxy.$saveProfile(id, name, content, token);
|
|
22
|
-
return result ? revive(result) : null;
|
|
23
|
-
},
|
|
24
|
-
readProfile: async (uri, token) => {
|
|
25
|
-
return this.proxy.$readProfile(id, uri, token);
|
|
26
|
-
},
|
|
27
|
-
}));
|
|
28
|
-
}
|
|
29
|
-
async $unregisterProfileContentHandler(id) {
|
|
30
|
-
this.registeredHandlers.deleteAndDispose(id);
|
|
31
|
-
}
|
|
32
|
-
};
|
|
33
|
-
MainThreadProfileContentHandlers = __decorate([
|
|
34
|
-
extHostNamedCustomer(MainContext.MainThreadProfileContentHandlers),
|
|
35
|
-
( __param(1, IUserDataProfileImportExportService))
|
|
36
|
-
], MainThreadProfileContentHandlers);
|
|
37
|
-
|
|
38
|
-
export { MainThreadProfileContentHandlers };
|
|
@@ -1,68 +0,0 @@
|
|
|
1
|
-
import { __decorate, __param } from '../../../../../../external/tslib/tslib.es6.js';
|
|
2
|
-
import { IProgressService } from 'vscode/vscode/vs/platform/progress/common/progress';
|
|
3
|
-
import { MainContext, ExtHostContext } from 'vscode/vscode/vs/workbench/api/common/extHost.protocol';
|
|
4
|
-
import { extHostNamedCustomer } from '../../services/extensions/common/extHostCustomers.js';
|
|
5
|
-
import { Action } from 'vscode/vscode/vs/base/common/actions';
|
|
6
|
-
import { ICommandService } from 'vscode/vscode/vs/platform/commands/common/commands';
|
|
7
|
-
import { localizeWithPath } from 'vscode/vscode/vs/nls';
|
|
8
|
-
|
|
9
|
-
class ManageExtensionAction extends Action {
|
|
10
|
-
constructor(extensionId, label, commandService) {
|
|
11
|
-
super(extensionId, label, undefined, true, () => {
|
|
12
|
-
return commandService.executeCommand('_extensions.manage', extensionId);
|
|
13
|
-
});
|
|
14
|
-
}
|
|
15
|
-
}
|
|
16
|
-
let MainThreadProgress = class MainThreadProgress {
|
|
17
|
-
constructor(extHostContext, progressService, _commandService) {
|
|
18
|
-
this._commandService = _commandService;
|
|
19
|
-
this._progress = ( new Map());
|
|
20
|
-
this._proxy = ( extHostContext.getProxy(ExtHostContext.ExtHostProgress));
|
|
21
|
-
this._progressService = progressService;
|
|
22
|
-
}
|
|
23
|
-
dispose() {
|
|
24
|
-
this._progress.forEach(handle => handle.resolve());
|
|
25
|
-
this._progress.clear();
|
|
26
|
-
}
|
|
27
|
-
async $startProgress(handle, options, extensionId) {
|
|
28
|
-
const task = this._createTask(handle);
|
|
29
|
-
if (options.location === 15 && extensionId) {
|
|
30
|
-
const notificationOptions = {
|
|
31
|
-
...options,
|
|
32
|
-
location: 15 ,
|
|
33
|
-
secondaryActions: [( new ManageExtensionAction(extensionId, ( localizeWithPath(
|
|
34
|
-
'vs/workbench/api/browser/mainThreadProgress',
|
|
35
|
-
'manageExtension',
|
|
36
|
-
"Manage Extension"
|
|
37
|
-
)), this._commandService))]
|
|
38
|
-
};
|
|
39
|
-
options = notificationOptions;
|
|
40
|
-
}
|
|
41
|
-
this._progressService.withProgress(options, task, () => this._proxy.$acceptProgressCanceled(handle));
|
|
42
|
-
}
|
|
43
|
-
$progressReport(handle, message) {
|
|
44
|
-
const entry = this._progress.get(handle);
|
|
45
|
-
entry?.progress.report(message);
|
|
46
|
-
}
|
|
47
|
-
$progressEnd(handle) {
|
|
48
|
-
const entry = this._progress.get(handle);
|
|
49
|
-
if (entry) {
|
|
50
|
-
entry.resolve();
|
|
51
|
-
this._progress.delete(handle);
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
_createTask(handle) {
|
|
55
|
-
return (progress) => {
|
|
56
|
-
return ( new Promise(resolve => {
|
|
57
|
-
this._progress.set(handle, { resolve, progress });
|
|
58
|
-
}));
|
|
59
|
-
};
|
|
60
|
-
}
|
|
61
|
-
};
|
|
62
|
-
MainThreadProgress = __decorate([
|
|
63
|
-
extHostNamedCustomer(MainContext.MainThreadProgress),
|
|
64
|
-
( __param(1, IProgressService)),
|
|
65
|
-
( __param(2, ICommandService))
|
|
66
|
-
], MainThreadProgress);
|
|
67
|
-
|
|
68
|
-
export { MainThreadProgress };
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
import { __decorate, __param } from '../../../../../../external/tslib/tslib.es6.js';
|
|
2
|
-
import { CancellationToken } from 'vscode/vscode/vs/base/common/cancellation';
|
|
3
|
-
import { DisposableMap } from 'vscode/vscode/vs/base/common/lifecycle';
|
|
4
|
-
import { URI } from 'vscode/vscode/vs/base/common/uri';
|
|
5
|
-
import { MainContext, ExtHostContext } from 'vscode/vscode/vs/workbench/api/common/extHost.protocol';
|
|
6
|
-
import { IQuickDiffService } from 'vscode/vscode/vs/workbench/contrib/scm/common/quickDiff';
|
|
7
|
-
import { extHostNamedCustomer } from '../../services/extensions/common/extHostCustomers.js';
|
|
8
|
-
|
|
9
|
-
let MainThreadQuickDiff = class MainThreadQuickDiff {
|
|
10
|
-
constructor(extHostContext, quickDiffService) {
|
|
11
|
-
this.quickDiffService = quickDiffService;
|
|
12
|
-
this.providerDisposables = ( new DisposableMap());
|
|
13
|
-
this.proxy = ( extHostContext.getProxy(ExtHostContext.ExtHostQuickDiff));
|
|
14
|
-
}
|
|
15
|
-
async $registerQuickDiffProvider(handle, selector, label, rootUri) {
|
|
16
|
-
const provider = {
|
|
17
|
-
label,
|
|
18
|
-
rootUri: URI.revive(rootUri),
|
|
19
|
-
selector,
|
|
20
|
-
isSCM: false,
|
|
21
|
-
getOriginalResource: async (uri) => {
|
|
22
|
-
return URI.revive(await this.proxy.$provideOriginalResource(handle, uri, CancellationToken.None));
|
|
23
|
-
}
|
|
24
|
-
};
|
|
25
|
-
const disposable = this.quickDiffService.addQuickDiffProvider(provider);
|
|
26
|
-
this.providerDisposables.set(handle, disposable);
|
|
27
|
-
}
|
|
28
|
-
async $unregisterQuickDiffProvider(handle) {
|
|
29
|
-
if (( this.providerDisposables.has(handle))) {
|
|
30
|
-
this.providerDisposables.deleteAndDispose(handle);
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
dispose() {
|
|
34
|
-
this.providerDisposables.dispose();
|
|
35
|
-
}
|
|
36
|
-
};
|
|
37
|
-
MainThreadQuickDiff = __decorate([
|
|
38
|
-
extHostNamedCustomer(MainContext.MainThreadQuickDiff),
|
|
39
|
-
( __param(1, IQuickDiffService))
|
|
40
|
-
], MainThreadQuickDiff);
|
|
41
|
-
|
|
42
|
-
export { MainThreadQuickDiff };
|
|
@@ -1,185 +0,0 @@
|
|
|
1
|
-
import { __decorate, __param } from '../../../../../../external/tslib/tslib.es6.js';
|
|
2
|
-
import { IQuickInputService } from 'vscode/vscode/vs/platform/quickinput/common/quickInput';
|
|
3
|
-
import { MainContext, ExtHostContext } from 'vscode/vscode/vs/workbench/api/common/extHost.protocol';
|
|
4
|
-
import { extHostNamedCustomer } from '../../services/extensions/common/extHostCustomers.js';
|
|
5
|
-
import { URI } from 'vscode/vscode/vs/base/common/uri';
|
|
6
|
-
|
|
7
|
-
function reviveIconPathUris(iconPath) {
|
|
8
|
-
iconPath.dark = URI.revive(iconPath.dark);
|
|
9
|
-
if (iconPath.light) {
|
|
10
|
-
iconPath.light = URI.revive(iconPath.light);
|
|
11
|
-
}
|
|
12
|
-
}
|
|
13
|
-
let MainThreadQuickOpen = class MainThreadQuickOpen {
|
|
14
|
-
constructor(extHostContext, quickInputService) {
|
|
15
|
-
this._items = {};
|
|
16
|
-
this.sessions = ( new Map());
|
|
17
|
-
this._proxy = ( extHostContext.getProxy(ExtHostContext.ExtHostQuickOpen));
|
|
18
|
-
this._quickInputService = quickInputService;
|
|
19
|
-
}
|
|
20
|
-
dispose() {
|
|
21
|
-
}
|
|
22
|
-
$show(instance, options, token) {
|
|
23
|
-
const contents = ( new Promise((resolve, reject) => {
|
|
24
|
-
this._items[instance] = { resolve, reject };
|
|
25
|
-
}));
|
|
26
|
-
options = {
|
|
27
|
-
...options,
|
|
28
|
-
onDidFocus: el => {
|
|
29
|
-
if (el) {
|
|
30
|
-
this._proxy.$onItemSelected(el.handle);
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
};
|
|
34
|
-
if (options.canPickMany) {
|
|
35
|
-
return this._quickInputService.pick(contents, options, token).then(items => {
|
|
36
|
-
if (items) {
|
|
37
|
-
return ( items.map(item => item.handle));
|
|
38
|
-
}
|
|
39
|
-
return undefined;
|
|
40
|
-
});
|
|
41
|
-
}
|
|
42
|
-
else {
|
|
43
|
-
return this._quickInputService.pick(contents, options, token).then(item => {
|
|
44
|
-
if (item) {
|
|
45
|
-
return item.handle;
|
|
46
|
-
}
|
|
47
|
-
return undefined;
|
|
48
|
-
});
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
$setItems(instance, items) {
|
|
52
|
-
if (this._items[instance]) {
|
|
53
|
-
this._items[instance].resolve(items);
|
|
54
|
-
delete this._items[instance];
|
|
55
|
-
}
|
|
56
|
-
return Promise.resolve();
|
|
57
|
-
}
|
|
58
|
-
$setError(instance, error) {
|
|
59
|
-
if (this._items[instance]) {
|
|
60
|
-
this._items[instance].reject(error);
|
|
61
|
-
delete this._items[instance];
|
|
62
|
-
}
|
|
63
|
-
return Promise.resolve();
|
|
64
|
-
}
|
|
65
|
-
$input(options, validateInput, token) {
|
|
66
|
-
const inputOptions = Object.create(null);
|
|
67
|
-
if (options) {
|
|
68
|
-
inputOptions.title = options.title;
|
|
69
|
-
inputOptions.password = options.password;
|
|
70
|
-
inputOptions.placeHolder = options.placeHolder;
|
|
71
|
-
inputOptions.valueSelection = options.valueSelection;
|
|
72
|
-
inputOptions.prompt = options.prompt;
|
|
73
|
-
inputOptions.value = options.value;
|
|
74
|
-
inputOptions.ignoreFocusLost = options.ignoreFocusOut;
|
|
75
|
-
}
|
|
76
|
-
if (validateInput) {
|
|
77
|
-
inputOptions.validateInput = (value) => {
|
|
78
|
-
return this._proxy.$validateInput(value);
|
|
79
|
-
};
|
|
80
|
-
}
|
|
81
|
-
return this._quickInputService.input(inputOptions, token);
|
|
82
|
-
}
|
|
83
|
-
$createOrUpdate(params) {
|
|
84
|
-
const sessionId = params.id;
|
|
85
|
-
let session = this.sessions.get(sessionId);
|
|
86
|
-
if (!session) {
|
|
87
|
-
const input = params.type === 'quickPick' ? this._quickInputService.createQuickPick() : this._quickInputService.createInputBox();
|
|
88
|
-
input.onDidAccept(() => {
|
|
89
|
-
this._proxy.$onDidAccept(sessionId);
|
|
90
|
-
});
|
|
91
|
-
input.onDidTriggerButton(button => {
|
|
92
|
-
this._proxy.$onDidTriggerButton(sessionId, button.handle);
|
|
93
|
-
});
|
|
94
|
-
input.onDidChangeValue(value => {
|
|
95
|
-
this._proxy.$onDidChangeValue(sessionId, value);
|
|
96
|
-
});
|
|
97
|
-
input.onDidHide(() => {
|
|
98
|
-
this._proxy.$onDidHide(sessionId);
|
|
99
|
-
});
|
|
100
|
-
if (params.type === 'quickPick') {
|
|
101
|
-
const quickpick = input;
|
|
102
|
-
quickpick.onDidChangeActive(items => {
|
|
103
|
-
this._proxy.$onDidChangeActive(sessionId, ( items.map(item => item.handle)));
|
|
104
|
-
});
|
|
105
|
-
quickpick.onDidChangeSelection(items => {
|
|
106
|
-
this._proxy.$onDidChangeSelection(sessionId, ( items.map(item => item.handle)));
|
|
107
|
-
});
|
|
108
|
-
quickpick.onDidTriggerItemButton((e) => {
|
|
109
|
-
this._proxy.$onDidTriggerItemButton(sessionId, e.item.handle, e.button.handle);
|
|
110
|
-
});
|
|
111
|
-
}
|
|
112
|
-
session = {
|
|
113
|
-
input,
|
|
114
|
-
handlesToItems: ( new Map())
|
|
115
|
-
};
|
|
116
|
-
this.sessions.set(sessionId, session);
|
|
117
|
-
}
|
|
118
|
-
const { input, handlesToItems } = session;
|
|
119
|
-
for (const param in params) {
|
|
120
|
-
if (param === 'id' || param === 'type') {
|
|
121
|
-
continue;
|
|
122
|
-
}
|
|
123
|
-
if (param === 'visible') {
|
|
124
|
-
if (params.visible) {
|
|
125
|
-
input.show();
|
|
126
|
-
}
|
|
127
|
-
else {
|
|
128
|
-
input.hide();
|
|
129
|
-
}
|
|
130
|
-
}
|
|
131
|
-
else if (param === 'items') {
|
|
132
|
-
handlesToItems.clear();
|
|
133
|
-
params[param].forEach((item) => {
|
|
134
|
-
if (item.type === 'separator') {
|
|
135
|
-
return;
|
|
136
|
-
}
|
|
137
|
-
if (item.buttons) {
|
|
138
|
-
item.buttons = ( item.buttons.map((button) => {
|
|
139
|
-
if (button.iconPath) {
|
|
140
|
-
reviveIconPathUris(button.iconPath);
|
|
141
|
-
}
|
|
142
|
-
return button;
|
|
143
|
-
}));
|
|
144
|
-
}
|
|
145
|
-
handlesToItems.set(item.handle, item);
|
|
146
|
-
});
|
|
147
|
-
input[param] = params[param];
|
|
148
|
-
}
|
|
149
|
-
else if (param === 'activeItems' || param === 'selectedItems') {
|
|
150
|
-
input[param] = ( params[param]
|
|
151
|
-
.filter((handle) => ( handlesToItems.has(handle)))
|
|
152
|
-
.map((handle) => handlesToItems.get(handle)));
|
|
153
|
-
}
|
|
154
|
-
else if (param === 'buttons') {
|
|
155
|
-
input[param] = ( params.buttons.map(button => {
|
|
156
|
-
if (button.handle === -1) {
|
|
157
|
-
return this._quickInputService.backButton;
|
|
158
|
-
}
|
|
159
|
-
if (button.iconPath) {
|
|
160
|
-
reviveIconPathUris(button.iconPath);
|
|
161
|
-
}
|
|
162
|
-
return button;
|
|
163
|
-
}));
|
|
164
|
-
}
|
|
165
|
-
else {
|
|
166
|
-
input[param] = params[param];
|
|
167
|
-
}
|
|
168
|
-
}
|
|
169
|
-
return Promise.resolve(undefined);
|
|
170
|
-
}
|
|
171
|
-
$dispose(sessionId) {
|
|
172
|
-
const session = this.sessions.get(sessionId);
|
|
173
|
-
if (session) {
|
|
174
|
-
session.input.dispose();
|
|
175
|
-
this.sessions.delete(sessionId);
|
|
176
|
-
}
|
|
177
|
-
return Promise.resolve(undefined);
|
|
178
|
-
}
|
|
179
|
-
};
|
|
180
|
-
MainThreadQuickOpen = __decorate([
|
|
181
|
-
extHostNamedCustomer(MainContext.MainThreadQuickOpen),
|
|
182
|
-
( __param(1, IQuickInputService))
|
|
183
|
-
], MainThreadQuickOpen);
|
|
184
|
-
|
|
185
|
-
export { MainThreadQuickOpen };
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import { __decorate, __param } from '../../../../../../external/tslib/tslib.es6.js';
|
|
2
|
-
import { extHostCustomer } from '../../services/extensions/common/extHostCustomers.js';
|
|
3
|
-
import { ExtHostContext } from 'vscode/vscode/vs/workbench/api/common/extHost.protocol';
|
|
4
|
-
import { IRemoteAuthorityResolverService } from 'vscode/vscode/vs/platform/remote/common/remoteAuthorityResolver';
|
|
5
|
-
import { Disposable } from 'vscode/vscode/vs/base/common/lifecycle';
|
|
6
|
-
import { IWorkbenchEnvironmentService } from 'vscode/vscode/vs/workbench/services/environment/common/environmentService';
|
|
7
|
-
|
|
8
|
-
let MainThreadRemoteConnectionData = class MainThreadRemoteConnectionData extends Disposable {
|
|
9
|
-
constructor(extHostContext, _environmentService, remoteAuthorityResolverService) {
|
|
10
|
-
super();
|
|
11
|
-
this._environmentService = _environmentService;
|
|
12
|
-
this._proxy = ( extHostContext.getProxy(ExtHostContext.ExtHostExtensionService));
|
|
13
|
-
const remoteAuthority = this._environmentService.remoteAuthority;
|
|
14
|
-
if (remoteAuthority) {
|
|
15
|
-
this._register(remoteAuthorityResolverService.onDidChangeConnectionData(() => {
|
|
16
|
-
const connectionData = remoteAuthorityResolverService.getConnectionData(remoteAuthority);
|
|
17
|
-
if (connectionData) {
|
|
18
|
-
this._proxy.$updateRemoteConnectionData(connectionData);
|
|
19
|
-
}
|
|
20
|
-
}));
|
|
21
|
-
}
|
|
22
|
-
}
|
|
23
|
-
};
|
|
24
|
-
MainThreadRemoteConnectionData = __decorate([
|
|
25
|
-
extHostCustomer,
|
|
26
|
-
( __param(1, IWorkbenchEnvironmentService)),
|
|
27
|
-
( __param(2, IRemoteAuthorityResolverService))
|
|
28
|
-
], MainThreadRemoteConnectionData);
|
|
29
|
-
|
|
30
|
-
export { MainThreadRemoteConnectionData };
|