@codingame/monaco-vscode-api 1.79.1 → 1.79.2-next.1
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 +11 -2
- package/dist/api.js +10 -8
- package/dist/composite.d.ts +65 -0
- package/dist/configurationRegistry.d.ts +212 -0
- package/dist/contextkey.d.ts +1 -1
- package/dist/default-extensions/json.js +1 -0
- package/dist/default-extensions/theme-defaults.js +2 -2
- package/dist/editorBrowser.d.ts +272 -3
- package/dist/event.d.ts +6 -1
- package/dist/{extension-tools-0c4c1ad7.js → extension-tools-3c2bf0a4.js} +698 -507
- package/dist/extensions.d.ts +3 -2
- package/dist/extensions.d2.ts +6 -17
- package/dist/extensionsRegistry.d.ts +15 -9
- package/dist/files.d.ts +71 -7
- package/dist/jsonSchema.d.ts +1 -1
- package/dist/keybinding.d.ts +2 -2
- package/dist/languageFeatures.d.ts +703 -61
- package/dist/monaco.d.ts +5 -4
- package/dist/override/vs/workbench/contrib/notebook/browser/contrib/find/findMatchDecorationModel.js +2 -0
- package/dist/override/vs/workbench/contrib/notebook/browser/notebookEditor.js +2 -0
- package/dist/override/vs/workbench/contrib/notebook/browser/notebookEditorWidget.js +2 -0
- package/dist/override/vs/workbench/contrib/notebook/common/notebookEditorInput.js +2 -1
- package/dist/platform.d.ts +11 -0
- package/dist/rollup-extension-directory-plugin.js +1 -1
- package/dist/rollup-vsix-plugin.js +2 -2
- package/dist/service-override/configuration.d.ts +5 -206
- package/dist/service-override/dialogs.js +16 -1
- package/dist/service-override/files.d.ts +2 -2
- package/dist/service-override/files.js +1 -1
- package/dist/service-override/markers.d.ts +7 -0
- package/dist/service-override/markers.js +6 -0
- package/dist/service-override/output.d.ts +7 -0
- package/dist/service-override/output.js +22 -0
- package/dist/service-override/preferences.js +7 -1
- package/dist/service-override/quickaccess.js +0 -9
- package/dist/service-override/search.d.ts +7 -0
- package/dist/service-override/search.js +19 -0
- package/dist/service-override/terminal.d.ts +607 -0
- package/dist/service-override/terminal.js +98 -0
- package/dist/service-override/tools/editor.js +1 -1
- package/dist/service-override/views.d.ts +561 -335
- package/dist/service-override/views.js +51 -11
- package/dist/services.d.ts +2627 -108
- package/dist/services.js +3 -0
- package/dist/severity.d.ts +16 -0
- package/dist/uri.d.ts +22 -11
- package/dist/views.d.ts +270 -0
- package/dist/vscode/vs/base/common/processes.js +24 -0
- package/dist/vscode/vs/editor/browser/widget/diffEditorWidget2/decorations.js +20 -0
- package/dist/vscode/vs/editor/browser/widget/diffEditorWidget2/delegatingEditorImpl.js +106 -0
- package/dist/vscode/vs/editor/browser/widget/diffEditorWidget2/diffEditorSash.js +59 -0
- package/dist/vscode/vs/editor/browser/widget/diffEditorWidget2/diffEditorWidget2.contribution.js +41 -0
- package/dist/vscode/vs/editor/browser/widget/diffEditorWidget2/diffEditorWidget2.js +369 -0
- package/dist/vscode/vs/editor/browser/widget/diffEditorWidget2/diffModel.js +247 -0
- package/dist/vscode/vs/editor/browser/widget/diffEditorWidget2/lineAlignment.js +179 -0
- package/dist/vscode/vs/editor/browser/widget/diffEditorWidget2/overviewRulerPart.js +121 -0
- package/dist/vscode/vs/editor/browser/widget/diffEditorWidget2/style.css.js +4 -0
- package/dist/vscode/vs/editor/browser/widget/diffEditorWidget2/unchangedRanges.js +184 -0
- package/dist/vscode/vs/editor/browser/widget/diffEditorWidget2/utils.js +88 -0
- package/dist/vscode/vs/platform/extensionManagement/common/extensionManagement.js +38 -1
- package/dist/vscode/vs/platform/extensionManagement/common/extensionManagementUtil.js +5 -1
- package/dist/vscode/vs/platform/extensionResourceLoader/common/extensionResourceLoader.js +13 -5
- package/dist/vscode/vs/platform/files/common/fileService.js +43 -5
- package/dist/vscode/vs/platform/files/common/files.js +3 -1
- package/dist/vscode/vs/platform/languagePacks/common/languagePacks.js +4 -1
- package/dist/vscode/vs/platform/log/common/bufferLog.js +34 -0
- package/dist/vscode/vs/platform/log/common/fileLog.js +105 -0
- package/dist/vscode/vs/platform/quickinput/browser/quickPickPin.js +1 -1
- package/dist/vscode/vs/platform/remote/common/remoteAuthorityResolver.js +20 -1
- package/dist/vscode/vs/platform/request/browser/requestService.js +1 -1
- package/dist/vscode/vs/platform/request/common/request.js +3 -3
- package/dist/vscode/vs/platform/storage/common/storage.js +3 -0
- package/dist/vscode/vs/platform/terminal/common/capabilities/bufferMarkCapability.js +39 -0
- package/dist/vscode/vs/platform/terminal/common/capabilities/commandDetectionCapability.js +565 -0
- package/dist/vscode/vs/platform/terminal/common/capabilities/cwdDetectionCapability.js +27 -0
- package/dist/vscode/vs/platform/terminal/common/capabilities/naiveCwdDetectionCapability.js +22 -0
- package/dist/vscode/vs/platform/terminal/common/capabilities/partialCommandDetectionCapability.js +46 -0
- package/dist/vscode/vs/platform/terminal/common/capabilities/terminalCapabilityStore.js +80 -0
- package/dist/vscode/vs/platform/terminal/common/environmentVariable.js +7 -0
- package/dist/vscode/vs/platform/terminal/common/environmentVariableCollection.js +196 -0
- package/dist/vscode/vs/platform/terminal/common/environmentVariableShared.js +23 -0
- package/dist/vscode/vs/platform/terminal/common/terminal.js +21 -1
- package/dist/vscode/vs/platform/terminal/common/terminalDataBuffering.js +45 -0
- package/dist/vscode/vs/platform/terminal/common/terminalEnvironment.js +37 -0
- package/dist/vscode/vs/platform/terminal/common/terminalPlatformConfiguration.js +622 -0
- package/dist/vscode/vs/platform/terminal/common/terminalProfiles.js +107 -0
- package/dist/vscode/vs/platform/terminal/common/terminalRecorder.js +66 -0
- package/dist/vscode/vs/platform/terminal/common/terminalStrings.js +16 -0
- package/dist/vscode/vs/platform/terminal/common/xterm/shellIntegrationAddon.js +321 -0
- package/dist/vscode/vs/platform/userDataSync/common/settingsMerge.js +39 -1
- package/dist/vscode/vs/platform/userDataSync/common/userDataSync.js +19 -0
- package/dist/vscode/vs/platform/window/common/window.js +7 -1
- package/dist/vscode/vs/platform/workspace/common/canonicalUri.js +3 -0
- package/dist/vscode/vs/platform/workspace/common/virtualWorkspace.js +4 -1
- package/dist/vscode/vs/platform/workspaces/common/workspaces.js +2 -2
- package/dist/vscode/vs/workbench/api/browser/mainThreadCommands.js +2 -3
- package/dist/vscode/vs/workbench/api/browser/mainThreadEditorTabs.js +473 -0
- package/dist/vscode/vs/workbench/api/browser/mainThreadLanguageFeatures.js +45 -38
- package/dist/vscode/vs/workbench/api/browser/mainThreadSearch.js +146 -0
- package/dist/vscode/vs/workbench/api/browser/mainThreadStatusBar.js +33 -52
- package/dist/vscode/vs/workbench/api/browser/mainThreadTerminalService.js +395 -0
- package/dist/vscode/vs/workbench/api/browser/mainThreadTheming.js +22 -0
- package/dist/vscode/vs/workbench/api/browser/mainThreadTreeViews.js +10 -5
- package/dist/vscode/vs/workbench/api/browser/mainThreadWindow.js +11 -4
- package/dist/vscode/vs/workbench/api/browser/mainThreadWorkspace.js +34 -11
- package/dist/vscode/vs/workbench/api/browser/statusBarExtensionPoint.js +81 -0
- package/dist/vscode/vs/workbench/api/common/extHost.protocol.js +7 -2
- package/dist/vscode/vs/workbench/api/common/extHostDebugService.js +4 -13
- package/dist/vscode/vs/workbench/api/common/extHostExtensionService.js +30 -15
- package/dist/vscode/vs/workbench/api/common/extHostFileSystemConsumer.js +20 -6
- package/dist/vscode/vs/workbench/api/common/extHostLanguageFeatures.js +41 -8
- package/dist/vscode/vs/workbench/api/common/extHostManagedSockets.js +3 -0
- package/dist/vscode/vs/workbench/api/common/extHostSearch.js +109 -0
- package/dist/vscode/vs/workbench/api/common/extHostStatusBar.js +33 -6
- package/dist/vscode/vs/workbench/api/common/extHostTerminalService.js +879 -1
- package/dist/vscode/vs/workbench/api/common/extHostTheming.js +38 -0
- package/dist/vscode/vs/workbench/api/common/extHostTreeViews.js +8 -5
- package/dist/vscode/vs/workbench/api/common/extHostTypeConverters.js +15 -17
- package/dist/vscode/vs/workbench/api/common/extHostTypes.js +117 -4
- package/dist/vscode/vs/workbench/api/common/extHostWindow.js +28 -6
- package/dist/vscode/vs/workbench/api/common/extHostWorkspace.js +28 -0
- package/dist/vscode/vs/workbench/api/common/shared/dataTransferCache.js +11 -14
- package/dist/vscode/vs/workbench/api/node/extHostTerminalService.js +22 -0
- package/dist/vscode/vs/workbench/browser/actions/layoutActions.js +2 -1
- package/dist/vscode/vs/workbench/browser/actions/windowActions.js +2 -2
- package/dist/vscode/vs/workbench/browser/dnd.js +56 -2
- package/dist/vscode/vs/workbench/browser/parts/compositePart.js +1 -1
- package/dist/vscode/vs/workbench/browser/parts/dialogs/dialogHandler.js +2 -2
- package/dist/vscode/vs/workbench/browser/parts/editor/editor.contribution.js +1 -0
- package/dist/vscode/vs/workbench/browser/parts/editor/editor.js +1 -0
- package/dist/vscode/vs/workbench/browser/parts/editor/editorCommands.js +9 -10
- package/dist/vscode/vs/workbench/browser/parts/editor/editorGroupView.js +15 -9
- package/dist/vscode/vs/workbench/browser/parts/editor/editorGroupWatermark.js +13 -17
- package/dist/vscode/vs/workbench/browser/parts/editor/editorStatus.js +1 -1
- package/dist/vscode/vs/workbench/browser/parts/editor/editorsObserver.js +2 -2
- package/dist/vscode/vs/workbench/browser/parts/editor/media/editorgroupview.css.js +1 -1
- package/dist/vscode/vs/workbench/browser/parts/editor/media/tabstitlecontrol.css.js +1 -1
- package/dist/vscode/vs/workbench/browser/parts/editor/noTabsTitleControl.js +3 -1
- package/dist/vscode/vs/workbench/browser/parts/editor/tabsTitleControl.js +60 -11
- package/dist/vscode/vs/workbench/browser/parts/editor/textDiffEditor.js +16 -10
- package/dist/vscode/vs/workbench/browser/parts/editor/textResourceEditor.js +1 -1
- package/dist/vscode/vs/workbench/browser/parts/statusbar/media/statusbarpart.css.js +1 -1
- package/dist/vscode/vs/workbench/browser/parts/views/checkbox.js +10 -0
- package/dist/vscode/vs/workbench/browser/parts/views/treeView.js +78 -14
- package/dist/vscode/vs/workbench/browser/parts/views/viewPaneContainer.js +1 -1
- package/dist/vscode/vs/workbench/browser/workbench.contribution.js +65 -6
- package/dist/vscode/vs/workbench/common/configuration.js +8 -1
- package/dist/vscode/vs/workbench/common/contextkeys.js +9 -1
- package/dist/vscode/vs/workbench/common/editor/editorGroupModel.js +5 -1
- package/dist/vscode/vs/workbench/common/editor/resourceEditorInput.js +6 -3
- package/dist/vscode/vs/workbench/common/editor/textResourceEditorInput.js +9 -6
- package/dist/vscode/vs/workbench/common/editor.js +1 -5
- package/dist/vscode/vs/workbench/common/resources.js +111 -34
- package/dist/vscode/vs/workbench/contrib/bulkEdit/browser/bulkEditService.js +1 -1
- package/dist/vscode/vs/workbench/contrib/bulkEdit/browser/bulkTextEdits.js +1 -1
- package/dist/vscode/vs/workbench/contrib/chat/browser/chat.js +3 -0
- package/dist/vscode/vs/workbench/contrib/chat/common/chatService.js +3 -0
- package/dist/vscode/vs/workbench/contrib/codeEditor/browser/languageConfigurationExtensionPoint.js +6 -4
- package/dist/vscode/vs/workbench/contrib/codeEditor/browser/suggestEnabledInput/suggestEnabledInput.css.js +4 -0
- package/dist/vscode/vs/workbench/contrib/codeEditor/browser/suggestEnabledInput/suggestEnabledInput.js +250 -0
- package/dist/vscode/vs/workbench/contrib/customEditor/browser/customEditorInput.js +290 -0
- package/dist/vscode/vs/workbench/contrib/customEditor/common/customEditor.js +3 -0
- package/dist/vscode/vs/workbench/contrib/debug/browser/debugActionViewItems.js +1 -0
- package/dist/vscode/vs/workbench/contrib/debug/browser/debugCommands.js +2 -1
- package/dist/vscode/vs/workbench/contrib/debug/browser/debugConfigurationManager.js +20 -20
- package/dist/vscode/vs/workbench/contrib/debug/browser/debugEditorActions.js +5 -3
- package/dist/vscode/vs/workbench/contrib/debug/browser/debugEditorContribution.js +5 -2
- package/dist/vscode/vs/workbench/contrib/debug/browser/debugHover.js +33 -6
- package/dist/vscode/vs/workbench/contrib/debug/browser/debugSession.js +1 -1
- package/dist/vscode/vs/workbench/contrib/debug/browser/debugTaskRunner.js +1 -1
- package/dist/vscode/vs/workbench/contrib/debug/browser/repl.js +3 -3
- package/dist/vscode/vs/workbench/contrib/debug/common/debugModel.js +29 -17
- package/dist/vscode/vs/workbench/contrib/debug/common/debugStorage.js +11 -10
- package/dist/vscode/vs/workbench/contrib/debug/common/debugger.js +10 -6
- package/dist/vscode/vs/workbench/contrib/extensions/browser/extensionsActions.js +2514 -0
- package/dist/vscode/vs/workbench/contrib/extensions/browser/extensionsIcons.js +82 -0
- package/dist/vscode/vs/workbench/contrib/extensions/browser/media/extensionActions.css.js +4 -0
- package/dist/vscode/vs/workbench/contrib/extensions/common/extensions.js +6 -1
- package/dist/vscode/vs/workbench/contrib/extensions/common/extensionsFileTemplate.js +16 -0
- package/dist/vscode/vs/workbench/contrib/files/browser/editors/fileEditorInput.js +2 -3
- package/dist/vscode/vs/workbench/contrib/files/browser/editors/textFileSaveErrorHandler.js +2 -0
- package/dist/vscode/vs/workbench/contrib/files/browser/explorerService.js +10 -6
- package/dist/vscode/vs/workbench/contrib/files/browser/explorerViewlet.js +3 -18
- package/dist/vscode/vs/workbench/contrib/files/browser/fileActions.contribution.js +37 -2
- package/dist/vscode/vs/workbench/contrib/files/browser/fileActions.js +65 -3
- package/dist/vscode/vs/workbench/contrib/files/browser/fileCommands.js +3 -3
- package/dist/vscode/vs/workbench/contrib/files/browser/fileConstants.js +3 -1
- package/dist/vscode/vs/workbench/contrib/files/browser/files.contribution.js +41 -6
- package/dist/vscode/vs/workbench/contrib/files/browser/files.js +1 -0
- package/dist/vscode/vs/workbench/contrib/files/browser/views/explorerView.js +3 -3
- package/dist/vscode/vs/workbench/contrib/files/browser/views/explorerViewer.js +6 -2
- package/dist/vscode/vs/workbench/contrib/files/common/explorerModel.js +16 -9
- package/dist/vscode/vs/workbench/contrib/files/common/files.js +1 -6
- package/dist/vscode/vs/workbench/contrib/interactive/browser/interactiveDocumentService.js +3 -0
- package/dist/vscode/vs/workbench/contrib/interactive/browser/interactiveEditorInput.js +200 -0
- package/dist/vscode/vs/workbench/contrib/interactive/browser/interactiveHistoryService.js +3 -0
- package/dist/vscode/vs/workbench/contrib/markers/browser/markers.contribution.js +586 -0
- package/dist/vscode/vs/workbench/contrib/markers/browser/markersFilterOptions.js +75 -0
- package/dist/vscode/vs/workbench/contrib/markers/browser/markersModel.js +201 -0
- package/dist/vscode/vs/workbench/contrib/markers/browser/markersTable.js +451 -0
- package/dist/vscode/vs/workbench/contrib/markers/browser/markersTreeViewer.js +670 -0
- package/dist/vscode/vs/workbench/contrib/markers/browser/markersView.js +857 -0
- package/dist/vscode/vs/workbench/contrib/markers/browser/markersViewActions.css.js +4 -0
- package/dist/vscode/vs/workbench/contrib/markers/browser/markersViewActions.js +132 -0
- package/dist/vscode/vs/workbench/contrib/markers/browser/media/markers.css.js +4 -0
- package/dist/vscode/vs/workbench/contrib/markers/browser/messages.js +171 -0
- package/dist/vscode/vs/workbench/contrib/markers/common/markers.js +15 -1
- package/dist/vscode/vs/workbench/contrib/mergeEditor/browser/mergeEditorInput.js +135 -0
- package/dist/vscode/vs/workbench/contrib/mergeEditor/browser/mergeEditorInputModel.js +421 -0
- package/dist/vscode/vs/workbench/contrib/mergeEditor/browser/mergeMarkers/mergeMarkersController.js +5 -0
- package/dist/vscode/vs/workbench/contrib/mergeEditor/browser/model/diffComputer.js +55 -0
- package/dist/vscode/vs/workbench/contrib/mergeEditor/browser/model/editing.js +54 -0
- package/dist/vscode/vs/workbench/contrib/mergeEditor/browser/model/lineRange.js +108 -0
- package/dist/vscode/vs/workbench/contrib/mergeEditor/browser/model/mapping.js +334 -0
- package/dist/vscode/vs/workbench/contrib/mergeEditor/browser/model/mergeEditorModel.js +606 -0
- package/dist/vscode/vs/workbench/contrib/mergeEditor/browser/model/modifiedBaseRange.js +307 -0
- package/dist/vscode/vs/workbench/contrib/mergeEditor/browser/model/rangeUtils.js +36 -0
- package/dist/vscode/vs/workbench/contrib/mergeEditor/browser/model/textModelDiffs.js +165 -0
- package/dist/vscode/vs/workbench/contrib/mergeEditor/browser/telemetry.js +78 -0
- package/dist/vscode/vs/workbench/contrib/mergeEditor/browser/utils.js +68 -0
- package/dist/vscode/vs/workbench/contrib/mergeEditor/common/mergeEditor.js +2 -0
- package/dist/vscode/vs/workbench/contrib/notebook/browser/contrib/find/findFilters.js +70 -0
- package/dist/vscode/vs/workbench/contrib/notebook/browser/contrib/find/notebookFindReplaceWidget.css.js +4 -0
- package/dist/vscode/vs/workbench/contrib/notebook/browser/contrib/find/notebookFindReplaceWidget.js +158 -0
- package/dist/vscode/vs/workbench/contrib/notebook/browser/notebookBrowser.js +6 -1
- package/dist/vscode/vs/workbench/contrib/notebook/browser/services/notebookEditorService.js +3 -0
- package/dist/vscode/vs/workbench/contrib/notebook/common/notebookCommon.js +16 -1
- package/dist/vscode/vs/workbench/contrib/notebook/common/notebookService.js +3 -0
- package/dist/vscode/vs/workbench/contrib/output/browser/logViewer.js +64 -0
- package/dist/vscode/vs/workbench/contrib/output/browser/output.contribution.js +378 -0
- package/dist/vscode/vs/workbench/contrib/output/browser/outputServices.js +39 -3
- package/dist/vscode/vs/workbench/contrib/output/browser/outputView.js +220 -0
- package/dist/vscode/vs/workbench/contrib/output/common/outputChannelModel.js +12 -3
- package/dist/vscode/vs/workbench/contrib/output/common/outputLinkComputer.js +129 -0
- package/dist/vscode/vs/workbench/contrib/preferences/browser/keybindingWidgets.js +270 -0
- package/dist/vscode/vs/workbench/contrib/preferences/browser/keybindingsEditor.js +1080 -0
- package/dist/vscode/vs/workbench/contrib/preferences/browser/media/keybindings.css.js +4 -0
- package/dist/vscode/vs/workbench/contrib/preferences/browser/media/keybindingsEditor.css.js +4 -0
- package/dist/vscode/vs/workbench/contrib/preferences/browser/media/preferences.css.js +4 -0
- package/dist/vscode/vs/workbench/contrib/preferences/browser/media/settingsEditor2.css.js +4 -0
- package/dist/vscode/vs/workbench/contrib/preferences/browser/media/settingsWidgets.css.js +4 -0
- package/dist/vscode/vs/workbench/contrib/preferences/browser/preferences.contribution.js +1154 -0
- package/dist/vscode/vs/workbench/contrib/preferences/browser/preferencesActions.js +94 -0
- package/dist/vscode/vs/workbench/contrib/preferences/browser/preferencesEditor.js +47 -0
- package/dist/vscode/vs/workbench/contrib/preferences/browser/preferencesIcons.js +37 -0
- package/dist/vscode/vs/workbench/contrib/preferences/browser/preferencesRenderers.js +731 -0
- package/dist/vscode/vs/workbench/contrib/preferences/browser/preferencesSearch.js +271 -0
- package/dist/vscode/vs/workbench/contrib/preferences/browser/preferencesWidgets.js +479 -0
- package/dist/vscode/vs/workbench/contrib/preferences/browser/settingsEditor2.js +1465 -0
- package/dist/vscode/vs/workbench/contrib/preferences/browser/settingsEditorSettingIndicators.js +506 -0
- package/dist/vscode/vs/workbench/contrib/preferences/browser/settingsLayout.js +296 -0
- package/dist/vscode/vs/workbench/contrib/preferences/browser/settingsSearchMenu.js +79 -0
- package/dist/vscode/vs/workbench/contrib/preferences/browser/settingsTree.js +1984 -0
- package/dist/vscode/vs/workbench/contrib/preferences/browser/settingsTreeModels.js +759 -0
- package/dist/vscode/vs/workbench/contrib/preferences/browser/settingsWidgets.js +1008 -0
- package/dist/vscode/vs/workbench/contrib/preferences/browser/tocTree.js +196 -0
- package/dist/vscode/vs/workbench/contrib/preferences/common/preferences.js +68 -0
- package/dist/vscode/vs/workbench/contrib/preferences/common/preferencesContribution.js +157 -0
- package/dist/vscode/vs/workbench/contrib/preferences/common/settingsEditorColorRegistry.js +67 -0
- package/dist/vscode/vs/workbench/contrib/quickaccess/browser/commandsQuickAccess.js +16 -16
- package/dist/vscode/vs/workbench/contrib/quickaccess/browser/quickAccess.contribution.js +1 -2
- package/dist/vscode/vs/workbench/contrib/remote/browser/remoteExplorer.js +23 -2
- package/dist/vscode/vs/workbench/contrib/remote/browser/tunnelView.js +5 -5
- package/dist/vscode/vs/workbench/contrib/search/browser/media/searchview.css.js +4 -0
- package/dist/vscode/vs/workbench/contrib/search/browser/patternInputWidget.js +217 -0
- package/dist/vscode/vs/workbench/contrib/search/browser/replace.js +3 -0
- package/dist/vscode/vs/workbench/contrib/search/browser/replaceContributions.js +7 -0
- package/dist/vscode/vs/workbench/contrib/search/browser/replaceService.js +222 -0
- package/dist/vscode/vs/workbench/contrib/search/browser/search.contribution.js +54 -15
- package/dist/vscode/vs/workbench/contrib/search/browser/searchActionsBase.js +17 -0
- package/dist/vscode/vs/workbench/contrib/search/browser/searchFindInput.js +41 -0
- package/dist/vscode/vs/workbench/contrib/search/browser/searchIcons.js +35 -0
- package/dist/vscode/vs/workbench/contrib/search/browser/searchMessage.js +58 -0
- package/dist/vscode/vs/workbench/contrib/search/browser/searchModel.js +1842 -0
- package/dist/vscode/vs/workbench/contrib/search/browser/searchNotebookHelpers.js +49 -0
- package/dist/vscode/vs/workbench/contrib/search/browser/searchResultsView.js +379 -0
- package/dist/vscode/vs/workbench/contrib/search/browser/searchView.js +1867 -0
- package/dist/vscode/vs/workbench/contrib/search/browser/searchWidget.js +628 -0
- package/dist/vscode/vs/workbench/contrib/search/common/constants.js +30 -1
- package/dist/vscode/vs/workbench/contrib/search/common/search.js +9 -1
- package/dist/vscode/vs/workbench/contrib/search/common/searchHistoryService.js +42 -0
- package/dist/vscode/vs/workbench/contrib/searchEditor/browser/constants.js +11 -0
- package/dist/vscode/vs/workbench/contrib/searchEditor/browser/media/searchEditor.css.js +4 -0
- package/dist/vscode/vs/workbench/contrib/searchEditor/browser/searchEditor.contribution.js +477 -0
- package/dist/vscode/vs/workbench/contrib/searchEditor/browser/searchEditor.js +697 -0
- package/dist/vscode/vs/workbench/contrib/searchEditor/browser/searchEditorActions.js +188 -0
- package/dist/vscode/vs/workbench/contrib/searchEditor/browser/searchEditorInput.js +295 -0
- package/dist/vscode/vs/workbench/contrib/searchEditor/browser/searchEditorModel.js +135 -0
- package/dist/vscode/vs/workbench/contrib/searchEditor/browser/searchEditorSerialization.js +268 -0
- package/dist/vscode/vs/workbench/contrib/snippets/browser/tabCompletion.js +2 -2
- package/dist/vscode/vs/workbench/contrib/tasks/common/taskService.js +16 -1
- package/dist/vscode/vs/workbench/contrib/terminal/browser/environmentVariableInfo.js +119 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/media/scrollbar.css.js +4 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/media/terminal.css.js +4 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/media/widgets.css.js +4 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/media/xterm.css.js +4 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminal.contribution.js +238 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminal.js +4 -1
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalActions.js +1930 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalCommands.js +22 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalConfigHelper.js +213 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalContextMenu.js +17 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalEditor.js +186 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalEditorInput.js +199 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalEditorService.js +239 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalExtensions.js +22 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalGroup.js +482 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalGroupService.js +372 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalIcon.js +60 -1
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalIcons.js +37 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalInstance.js +2123 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalInstanceService.js +79 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalMainContribution.js +82 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalMenus.js +850 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalProcessExtHostProxy.js +142 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalProcessManager.js +618 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalProfileQuickpick.js +278 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalProfileResolverService.js +417 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalProfileService.js +213 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalQuickAccess.js +144 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalRunRecentQuickPick.js +267 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalService.js +1063 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalStatusList.js +108 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalTabbedView.js +417 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalTabsList.js +680 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalTooltip.js +72 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalUri.js +39 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/terminalView.js +535 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/widgets/widgetManager.js +36 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/xterm/decorationAddon.js +469 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/xterm/decorationStyles.js +97 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/xterm/lineDataEventAddon.js +56 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/xterm/markNavigationAddon.js +416 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/xterm/suggestAddon.js +390 -0
- package/dist/vscode/vs/workbench/contrib/terminal/browser/xterm/xtermTerminal.js +587 -0
- package/dist/vscode/vs/workbench/contrib/terminal/common/environmentVariable.js +3 -0
- package/dist/vscode/vs/workbench/contrib/terminal/common/environmentVariableService.js +94 -0
- package/dist/vscode/vs/workbench/contrib/terminal/common/history.js +356 -0
- package/dist/vscode/vs/workbench/contrib/terminal/common/terminal.js +266 -0
- package/dist/vscode/vs/workbench/contrib/terminal/common/terminalColorRegistry.js +23 -16
- package/dist/vscode/vs/workbench/contrib/terminal/common/terminalConfiguration.js +965 -0
- package/dist/vscode/vs/workbench/contrib/terminal/common/terminalContextKey.js +157 -0
- package/dist/vscode/vs/workbench/contrib/terminal/common/terminalEnvironment.js +272 -0
- package/dist/vscode/vs/workbench/contrib/terminal/common/terminalExtensionPoints.js +27 -0
- package/dist/vscode/vs/workbench/contrib/terminal/common/terminalStrings.js +86 -0
- package/dist/vscode/vs/workbench/contrib/terminal/electron-sandbox/terminalProfileResolverService.js +46 -0
- package/dist/vscode/vs/workbench/contrib/terminalContrib/links/browser/links.js +3 -0
- package/dist/vscode/vs/workbench/contrib/terminalContrib/links/browser/terminalLinkProviderService.js +26 -0
- package/dist/vscode/vs/workbench/contrib/terminalContrib/quickFix/browser/quickFix.js +3 -0
- package/dist/vscode/vs/workbench/contrib/terminalContrib/quickFix/browser/terminalQuickFixService.js +143 -0
- package/dist/vscode/vs/workbench/contrib/webviewPanel/browser/webviewEditorInput.js +85 -0
- package/dist/vscode/vs/workbench/contrib/webviewPanel/browser/webviewWorkbenchService.js +52 -0
- package/dist/vscode/vs/workbench/services/actions/common/menusExtensionPoint.js +14 -6
- package/dist/vscode/vs/workbench/services/assignment/common/assignmentService.js +3 -0
- package/dist/vscode/vs/workbench/services/configuration/browser/configurationService.js +13 -13
- package/dist/vscode/vs/workbench/services/configuration/common/configuration.js +2 -1
- package/dist/vscode/vs/workbench/services/configuration/common/configurationEditing.js +2 -2
- package/dist/vscode/vs/workbench/services/configuration/common/jsonEditingService.js +2 -2
- package/dist/vscode/vs/workbench/services/dialogs/browser/abstractFileDialogService.js +302 -0
- package/dist/vscode/vs/workbench/services/dialogs/browser/simpleFileDialog.js +971 -0
- package/dist/vscode/vs/workbench/services/extensionManagement/common/extensionManagement.js +3 -2
- package/dist/vscode/vs/workbench/services/extensionRecommendations/common/extensionRecommendations.js +4 -0
- package/dist/vscode/vs/workbench/services/extensionRecommendations/common/workspaceExtensionsConfig.js +2 -0
- package/dist/vscode/vs/workbench/services/extensions/common/extensionManifestPropertiesService.js +3 -0
- package/dist/vscode/vs/workbench/services/extensions/common/extensions.js +14 -2
- package/dist/vscode/vs/workbench/services/extensions/common/extensionsApiProposals.js +10 -1
- package/dist/vscode/vs/workbench/services/filesConfiguration/common/filesConfigurationService.js +70 -3
- package/dist/vscode/vs/workbench/services/hover/browser/hoverService.js +1 -1
- package/dist/vscode/vs/workbench/services/hover/browser/hoverWidget.js +2 -1
- package/dist/vscode/vs/workbench/services/hover/browser/media/hover.css.js +1 -1
- package/dist/vscode/vs/workbench/services/keybinding/common/keybindingEditing.js +275 -0
- package/dist/vscode/vs/workbench/services/localization/common/locale.js +3 -0
- package/dist/vscode/vs/workbench/services/log/common/logConstants.js +2 -0
- package/dist/vscode/vs/workbench/services/output/common/output.js +4 -1
- package/dist/vscode/vs/workbench/services/preferences/common/preferences.js +22 -1
- package/dist/vscode/vs/workbench/services/preferences/common/preferencesModels.js +6 -0
- package/dist/vscode/vs/workbench/services/preferences/common/preferencesValidation.js +37 -1
- package/dist/vscode/vs/workbench/services/remote/common/remoteAgentService.js +69 -0
- package/dist/vscode/vs/workbench/services/remote/common/remoteExplorerService.js +66 -27
- package/dist/vscode/vs/workbench/services/search/common/fileSearchManager.js +265 -0
- package/dist/vscode/vs/workbench/services/search/common/queryBuilder.js +6 -0
- package/dist/vscode/vs/workbench/services/search/common/replace.js +203 -0
- package/dist/vscode/vs/workbench/services/search/common/search.js +227 -1
- package/dist/vscode/vs/workbench/services/search/common/searchExtTypes.js +6 -0
- package/dist/vscode/vs/workbench/services/search/common/searchHelpers.js +72 -0
- package/dist/vscode/vs/workbench/services/search/common/searchService.js +355 -0
- package/dist/vscode/vs/workbench/services/search/common/textSearchManager.js +309 -0
- package/dist/vscode/vs/workbench/services/suggest/browser/media/suggest.css.js +4 -0
- package/dist/vscode/vs/workbench/services/suggest/browser/simpleCompletionItem.js +10 -0
- package/dist/vscode/vs/workbench/services/suggest/browser/simpleCompletionModel.js +98 -0
- package/dist/vscode/vs/workbench/services/suggest/browser/simpleSuggestWidget.js +399 -0
- package/dist/vscode/vs/workbench/services/suggest/browser/simpleSuggestWidgetRenderer.js +83 -0
- package/dist/vscode/vs/workbench/services/terminal/common/embedderTerminalService.js +3 -0
- package/dist/vscode/vs/workbench/services/textfile/browser/textFileService.js +1 -1
- package/dist/vscode/vs/workbench/services/textfile/common/textFileEditorModel.js +10 -3
- package/dist/vscode/vs/workbench/services/themes/browser/fileIconThemeData.js +3 -3
- package/dist/vscode/vs/workbench/services/themes/browser/productIconThemeData.js +3 -3
- package/dist/vscode/vs/workbench/services/themes/common/colorThemeData.js +3 -3
- package/dist/vscode/vs/workbench/services/untitled/common/untitledTextEditorInput.js +6 -4
- package/dist/vscode/vs/workbench/services/untitled/common/untitledTextEditorModel.js +3 -0
- package/dist/vscode/vs/workbench/services/untitled/common/untitledTextEditorService.js +4 -0
- package/dist/vscode/vs/workbench/services/userActivity/common/userActivityRegistry.js +15 -0
- package/dist/vscode/vs/workbench/services/userActivity/common/userActivityService.js +37 -0
- package/dist/vscode/vs/workbench/services/userDataSync/common/userDataSync.js +7 -0
- package/dist/vscode/vs/workbench/services/workingCopy/common/workingCopyEditorService.js +40 -0
- package/dist/vscode/vs/workbench/services/workingCopy/common/workingCopyService.js +12 -0
- package/dist/vscode/vs/workbench/services/workspaces/common/canonicalUriService.js +19 -0
- package/dist/vscode-default-extensions/css/syntaxes/css.tmLanguage.json.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/json/package.json.js +1 -1
- package/dist/vscode-default-extensions/json/syntaxes/JSONC.tmLanguage.json.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/json/syntaxes/JSONL.tmLanguage.json.extensionResource.js +2 -0
- package/dist/vscode-default-extensions/latex/syntaxes/Bibtex.tmLanguage.json.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/latex/syntaxes/LaTeX.tmLanguage.json.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/latex/syntaxes/TeX.tmLanguage.json.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/latex/syntaxes/cpp-grammar-bailout.tmLanguage.json.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/latex/syntaxes/markdown-latex-combined.tmLanguage.json.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/lua/syntaxes/lua.tmLanguage.json.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/perl/package.json.js +1 -1
- package/dist/vscode-default-extensions/php/snippets/php.code-snippets.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/sql/language-configuration.json.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/theme-abyss/themes/abyss-color-theme.json.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/theme-defaults/package.json.js +1 -1
- package/dist/vscode-default-extensions/theme-defaults/themes/dark_modern.json.extensionResource.js +2 -0
- package/dist/vscode-default-extensions/theme-defaults/themes/dark_vs.json.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/theme-defaults/themes/hc_black.json.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/theme-defaults/themes/hc_light.json.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/theme-defaults/themes/light_modern.json.extensionResource.js +2 -0
- package/dist/vscode-default-extensions/theme-defaults/themes/light_vs.json.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/theme-kimbie-dark/themes/kimbie-dark-color-theme.json.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/theme-monokai/themes/monokai-color-theme.json.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/theme-monokai-dimmed/themes/dimmed-monokai-color-theme.json.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/theme-quietlight/themes/quietlight-color-theme.json.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/theme-red/themes/Red-color-theme.json.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/theme-seti/icons/vs-seti-icon-theme.json.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/theme-solarized-light/themes/solarized-light-color-theme.json.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/theme-tomorrow-night-blue/themes/tomorrow-night-blue-color-theme.json.extensionResource.js +1 -1
- package/dist/vscode-default-extensions/vb/language-configuration.json.extensionResource.js +1 -1
- package/dist/vscode-services/env.js +4 -2
- package/dist/vscode-services/extHost.js +32 -48
- package/dist/vscode-services/missing-services.js +407 -29
- package/dist/vscode-services/window.js +59 -65
- package/dist/vscode-services/workspace.js +19 -5
- package/dist/workers/outputLinkComputer.worker.d.ts +2 -0
- package/dist/workers/outputLinkComputer.worker.js +3 -0
- package/dist/workspace.d.ts +1 -1
- package/monaco-editor-treemending.patch +1305 -1184
- package/package.json +65 -19
- package/dist/activity.d.ts +0 -2802
- package/dist/collections.d.ts +0 -7
- package/dist/colorRegistry.d.ts +0 -710
- package/dist/vscode/vs/platform/product/common/product.js +0 -48
- package/dist/vscode/vs/workbench/contrib/interactiveSession/browser/interactiveSessionFollowups.js +0 -30
- package/dist/vscode/vs/workbench/contrib/interactiveSession/browser/interactiveSessionInputPart.js +0 -196
- package/dist/vscode/vs/workbench/contrib/interactiveSession/browser/interactiveSessionListRenderer.js +0 -622
- package/dist/vscode/vs/workbench/contrib/interactiveSession/browser/interactiveSessionOptions.js +0 -77
- package/dist/vscode/vs/workbench/contrib/interactiveSession/browser/interactiveSessionWidget.js +0 -311
- package/dist/vscode/vs/workbench/contrib/interactiveSession/browser/media/interactiveSession.css.js +0 -4
- package/dist/vscode/vs/workbench/contrib/interactiveSession/common/interactiveSessionContextKeys.js +0 -56
- package/dist/vscode/vs/workbench/contrib/interactiveSession/common/interactiveSessionModel.js +0 -305
- package/dist/vscode/vs/workbench/contrib/interactiveSession/common/interactiveSessionService.js +0 -13
- package/dist/vscode/vs/workbench/contrib/interactiveSession/common/interactiveSessionServiceImpl.js +0 -379
- package/dist/vscode/vs/workbench/contrib/interactiveSession/common/interactiveSessionViewModel.js +0 -207
- package/dist/vscode/vs/workbench/contrib/interactiveSession/common/interactiveSessionWidgetHistoryService.js +0 -3
- package/dist/vscode/vs/workbench/contrib/interactiveSession/common/interactiveSessionWordCounter.js +0 -25
- package/dist/vscode-default-extensions/theme-defaults/themes/dark_plus_experimental.json.extensionResource.js +0 -2
- package/dist/vscode-default-extensions/theme-defaults/themes/light_plus_experimental.json.extensionResource.js +0 -2
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
import { __decorate, __param } from '../../../../../node_modules/tslib/tslib.es6.js';
|
|
2
|
+
import { CancellationToken } from 'monaco-editor/esm/vs/base/common/cancellation.js';
|
|
3
|
+
import { dispose, DisposableStore } from 'monaco-editor/esm/vs/base/common/lifecycle.js';
|
|
4
|
+
import { URI } from 'monaco-editor/esm/vs/base/common/uri.js';
|
|
5
|
+
import { IConfigurationService } from 'monaco-editor/esm/vs/platform/configuration/common/configuration.js';
|
|
6
|
+
import { ITelemetryService } from 'monaco-editor/esm/vs/platform/telemetry/common/telemetry.js';
|
|
7
|
+
import { extHostNamedCustomer } from '../../services/extensions/common/extHostCustomers.js';
|
|
8
|
+
import { ISearchService } from '../../services/search/common/search.js';
|
|
9
|
+
import { ExtHostContext, MainContext } from '../common/extHost.protocol.js';
|
|
10
|
+
let MainThreadSearch = class MainThreadSearch {
|
|
11
|
+
constructor(extHostContext, _searchService, _telemetryService, _configurationService) {
|
|
12
|
+
this._searchService = _searchService;
|
|
13
|
+
this._telemetryService = _telemetryService;
|
|
14
|
+
this._searchProvider = ( new Map());
|
|
15
|
+
this._proxy = ( extHostContext.getProxy(ExtHostContext.ExtHostSearch));
|
|
16
|
+
this._proxy.$enableExtensionHostSearch();
|
|
17
|
+
}
|
|
18
|
+
dispose() {
|
|
19
|
+
this._searchProvider.forEach(value => value.dispose());
|
|
20
|
+
this._searchProvider.clear();
|
|
21
|
+
}
|
|
22
|
+
$registerTextSearchProvider(handle, scheme) {
|
|
23
|
+
this._searchProvider.set(handle, ( new RemoteSearchProvider(
|
|
24
|
+
this._searchService,
|
|
25
|
+
1 ,
|
|
26
|
+
scheme,
|
|
27
|
+
handle,
|
|
28
|
+
this._proxy
|
|
29
|
+
)));
|
|
30
|
+
}
|
|
31
|
+
$registerFileSearchProvider(handle, scheme) {
|
|
32
|
+
this._searchProvider.set(handle, ( new RemoteSearchProvider(
|
|
33
|
+
this._searchService,
|
|
34
|
+
0 ,
|
|
35
|
+
scheme,
|
|
36
|
+
handle,
|
|
37
|
+
this._proxy
|
|
38
|
+
)));
|
|
39
|
+
}
|
|
40
|
+
$unregisterProvider(handle) {
|
|
41
|
+
dispose(this._searchProvider.get(handle));
|
|
42
|
+
this._searchProvider.delete(handle);
|
|
43
|
+
}
|
|
44
|
+
$handleFileMatch(handle, session, data) {
|
|
45
|
+
const provider = this._searchProvider.get(handle);
|
|
46
|
+
if (!provider) {
|
|
47
|
+
throw new Error('Got result for unknown provider');
|
|
48
|
+
}
|
|
49
|
+
provider.handleFindMatch(session, data);
|
|
50
|
+
}
|
|
51
|
+
$handleTextMatch(handle, session, data) {
|
|
52
|
+
const provider = this._searchProvider.get(handle);
|
|
53
|
+
if (!provider) {
|
|
54
|
+
throw new Error('Got result for unknown provider');
|
|
55
|
+
}
|
|
56
|
+
provider.handleFindMatch(session, data);
|
|
57
|
+
}
|
|
58
|
+
$handleTelemetry(eventName, data) {
|
|
59
|
+
this._telemetryService.publicLog(eventName, data);
|
|
60
|
+
}
|
|
61
|
+
};
|
|
62
|
+
MainThreadSearch = __decorate([
|
|
63
|
+
extHostNamedCustomer(MainContext.MainThreadSearch),
|
|
64
|
+
( __param(1, ISearchService)),
|
|
65
|
+
( __param(2, ITelemetryService)),
|
|
66
|
+
( __param(3, IConfigurationService))
|
|
67
|
+
], MainThreadSearch);
|
|
68
|
+
class SearchOperation {
|
|
69
|
+
constructor(progress, id = ++SearchOperation._idPool, matches = ( new Map())) {
|
|
70
|
+
this.progress = progress;
|
|
71
|
+
this.id = id;
|
|
72
|
+
this.matches = matches;
|
|
73
|
+
}
|
|
74
|
+
addMatch(match) {
|
|
75
|
+
const existingMatch = this.matches.get(( match.resource.toString()));
|
|
76
|
+
if (existingMatch) {
|
|
77
|
+
if (existingMatch.results && match.results) {
|
|
78
|
+
existingMatch.results.push(...match.results);
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
else {
|
|
82
|
+
this.matches.set(( match.resource.toString()), match);
|
|
83
|
+
}
|
|
84
|
+
this.progress?.(match);
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
SearchOperation._idPool = 0;
|
|
88
|
+
class RemoteSearchProvider {
|
|
89
|
+
constructor(searchService, type, _scheme, _handle, _proxy) {
|
|
90
|
+
this._scheme = _scheme;
|
|
91
|
+
this._handle = _handle;
|
|
92
|
+
this._proxy = _proxy;
|
|
93
|
+
this._registrations = ( new DisposableStore());
|
|
94
|
+
this._searches = ( new Map());
|
|
95
|
+
this._registrations.add(searchService.registerSearchResultProvider(this._scheme, type, this));
|
|
96
|
+
}
|
|
97
|
+
dispose() {
|
|
98
|
+
this._registrations.dispose();
|
|
99
|
+
}
|
|
100
|
+
fileSearch(query, token = CancellationToken.None) {
|
|
101
|
+
return this.doSearch(query, undefined, token);
|
|
102
|
+
}
|
|
103
|
+
textSearch(query, onProgress, token = CancellationToken.None) {
|
|
104
|
+
return this.doSearch(query, onProgress, token);
|
|
105
|
+
}
|
|
106
|
+
doSearch(query, onProgress, token = CancellationToken.None) {
|
|
107
|
+
if (!query.folderQueries.length) {
|
|
108
|
+
throw new Error('Empty folderQueries');
|
|
109
|
+
}
|
|
110
|
+
const search = ( new SearchOperation(onProgress));
|
|
111
|
+
this._searches.set(search.id, search);
|
|
112
|
+
const searchP = query.type === 1
|
|
113
|
+
? this._proxy.$provideFileSearchResults(this._handle, search.id, query, token)
|
|
114
|
+
: this._proxy.$provideTextSearchResults(this._handle, search.id, query, token);
|
|
115
|
+
return Promise.resolve(searchP).then((result) => {
|
|
116
|
+
this._searches.delete(search.id);
|
|
117
|
+
return { results: Array.from(( search.matches.values())), stats: result.stats, limitHit: result.limitHit, messages: result.messages };
|
|
118
|
+
}, err => {
|
|
119
|
+
this._searches.delete(search.id);
|
|
120
|
+
return Promise.reject(err);
|
|
121
|
+
});
|
|
122
|
+
}
|
|
123
|
+
clearCache(cacheKey) {
|
|
124
|
+
return Promise.resolve(this._proxy.$clearCache(cacheKey));
|
|
125
|
+
}
|
|
126
|
+
handleFindMatch(session, dataOrUri) {
|
|
127
|
+
const searchOp = this._searches.get(session);
|
|
128
|
+
if (!searchOp) {
|
|
129
|
+
return;
|
|
130
|
+
}
|
|
131
|
+
dataOrUri.forEach(result => {
|
|
132
|
+
if (result.results) {
|
|
133
|
+
searchOp.addMatch({
|
|
134
|
+
resource: URI.revive(result.resource),
|
|
135
|
+
results: result.results
|
|
136
|
+
});
|
|
137
|
+
}
|
|
138
|
+
else {
|
|
139
|
+
searchOp.addMatch({
|
|
140
|
+
resource: URI.revive(result)
|
|
141
|
+
});
|
|
142
|
+
}
|
|
143
|
+
});
|
|
144
|
+
}
|
|
145
|
+
}
|
|
146
|
+
export { MainThreadSearch };
|
|
@@ -1,68 +1,49 @@
|
|
|
1
1
|
import { __decorate, __param } from '../../../../../node_modules/tslib/tslib.es6.js';
|
|
2
|
-
import {
|
|
3
|
-
import { MainContext } from '../common/extHost.protocol.js';
|
|
2
|
+
import { MainContext, ExtHostContext } from '../common/extHost.protocol.js';
|
|
4
3
|
import { extHostNamedCustomer } from '../../services/extensions/common/extHostCustomers.js';
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import { hash } from 'monaco-editor/esm/vs/base/common/hash.js';
|
|
4
|
+
import { DisposableMap } from 'monaco-editor/esm/vs/base/common/lifecycle.js';
|
|
5
|
+
import { IExtensionStatusBarItemService } from './statusBarExtensionPoint.js';
|
|
8
6
|
let MainThreadStatusBar = class MainThreadStatusBar {
|
|
9
|
-
constructor(
|
|
7
|
+
constructor(extHostContext, statusbarService) {
|
|
10
8
|
this.statusbarService = statusbarService;
|
|
11
|
-
this.entries = ( new
|
|
9
|
+
this.entries = ( new DisposableMap());
|
|
10
|
+
const proxy = ( extHostContext.getProxy(ExtHostContext.ExtHostStatusBar));
|
|
11
|
+
const entries = [];
|
|
12
|
+
for (const [entryId, item] of statusbarService.getEntries()) {
|
|
13
|
+
entries.push(asDto(entryId, item));
|
|
14
|
+
}
|
|
15
|
+
proxy.$acceptStaticEntries(entries);
|
|
16
|
+
statusbarService.onDidChange(e => {
|
|
17
|
+
if (e.added) {
|
|
18
|
+
proxy.$acceptStaticEntries([asDto(e.added[0], e.added[1])]);
|
|
19
|
+
}
|
|
20
|
+
});
|
|
21
|
+
function asDto(entryId, item) {
|
|
22
|
+
return {
|
|
23
|
+
entryId,
|
|
24
|
+
name: item.entry.name,
|
|
25
|
+
text: item.entry.text,
|
|
26
|
+
command: typeof item.entry.command === 'string' ? item.entry.command : typeof item.entry.command === 'object' ? item.entry.command.id : undefined,
|
|
27
|
+
priority: item.priority,
|
|
28
|
+
alignLeft: item.alignment === 0
|
|
29
|
+
};
|
|
30
|
+
}
|
|
12
31
|
}
|
|
13
32
|
dispose() {
|
|
14
|
-
this.entries.
|
|
15
|
-
this.entries.clear();
|
|
33
|
+
this.entries.dispose();
|
|
16
34
|
}
|
|
17
35
|
$setEntry(entryId, id, extensionId, name, text, tooltip, command, color, backgroundColor, alignLeft, priority, accessibilityInformation) {
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
ariaLabel = accessibilityInformation.label;
|
|
22
|
-
role = accessibilityInformation.role;
|
|
23
|
-
}
|
|
24
|
-
else {
|
|
25
|
-
ariaLabel = getCodiconAriaLabel(text);
|
|
26
|
-
if (tooltip) {
|
|
27
|
-
const tooltipString = typeof tooltip === 'string' ? tooltip : tooltip.value;
|
|
28
|
-
ariaLabel += `, ${tooltipString}`;
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
const entry = { name, text, tooltip, command, color, backgroundColor, ariaLabel, role };
|
|
32
|
-
if (typeof priority === 'undefined') {
|
|
33
|
-
priority = 0;
|
|
34
|
-
}
|
|
35
|
-
const alignment = alignLeft ? 0 : 1 ;
|
|
36
|
-
let existingEntry = this.entries.get(entryId);
|
|
37
|
-
if (existingEntry && (existingEntry.alignment !== alignment || existingEntry.priority !== priority)) {
|
|
38
|
-
dispose(existingEntry.accessor);
|
|
39
|
-
this.entries.delete(entryId);
|
|
40
|
-
existingEntry = undefined;
|
|
41
|
-
}
|
|
42
|
-
if (!existingEntry) {
|
|
43
|
-
let entryPriority;
|
|
44
|
-
if (typeof extensionId === 'string') {
|
|
45
|
-
entryPriority = { primary: priority, secondary: hash(extensionId) };
|
|
46
|
-
}
|
|
47
|
-
else {
|
|
48
|
-
entryPriority = priority;
|
|
49
|
-
}
|
|
50
|
-
this.entries.set(entryId, { accessor: this.statusbarService.addEntry(entry, id, alignment, entryPriority), alignment, priority });
|
|
51
|
-
}
|
|
52
|
-
else {
|
|
53
|
-
existingEntry.accessor.update(entry);
|
|
36
|
+
const dispo = this.statusbarService.setOrUpdateEntry(entryId, id, extensionId, name, text, tooltip, command, color, backgroundColor, alignLeft, priority, accessibilityInformation);
|
|
37
|
+
if (!( this.entries.has(entryId))) {
|
|
38
|
+
this.entries.set(entryId, dispo);
|
|
54
39
|
}
|
|
55
40
|
}
|
|
56
|
-
$
|
|
57
|
-
|
|
58
|
-
if (entry) {
|
|
59
|
-
dispose(entry.accessor);
|
|
60
|
-
this.entries.delete(id);
|
|
61
|
-
}
|
|
41
|
+
$disposeEntry(entryId) {
|
|
42
|
+
this.entries.deleteAndDispose(entryId);
|
|
62
43
|
}
|
|
63
44
|
};
|
|
64
45
|
MainThreadStatusBar = __decorate([
|
|
65
46
|
extHostNamedCustomer(MainContext.MainThreadStatusBar),
|
|
66
|
-
( __param(1,
|
|
47
|
+
( __param(1, IExtensionStatusBarItemService))
|
|
67
48
|
], MainThreadStatusBar);
|
|
68
49
|
export { MainThreadStatusBar };
|
|
@@ -0,0 +1,395 @@
|
|
|
1
|
+
import { __decorate, __param } from '../../../../../node_modules/tslib/tslib.es6.js';
|
|
2
|
+
import { DisposableStore, Disposable } from 'monaco-editor/esm/vs/base/common/lifecycle.js';
|
|
3
|
+
import { ExtHostContext, MainContext } from '../common/extHost.protocol.js';
|
|
4
|
+
import { extHostNamedCustomer } from '../../services/extensions/common/extHostCustomers.js';
|
|
5
|
+
import { URI } from 'monaco-editor/esm/vs/base/common/uri.js';
|
|
6
|
+
import { StopWatch } from 'monaco-editor/esm/vs/base/common/stopwatch.js';
|
|
7
|
+
import { IInstantiationService } from 'monaco-editor/esm/vs/platform/instantiation/common/instantiation.js';
|
|
8
|
+
import { ILogService } from 'monaco-editor/esm/vs/platform/log/common/log.js';
|
|
9
|
+
import { TerminalLocation, TerminalExitReason } from '../../../platform/terminal/common/terminal.js';
|
|
10
|
+
import { TerminalDataBufferer } from '../../../platform/terminal/common/terminalDataBuffering.js';
|
|
11
|
+
import { ITerminalService, ITerminalGroupService, ITerminalEditorService } from '../../contrib/terminal/browser/terminal.js';
|
|
12
|
+
import { TerminalProcessExtHostProxy } from '../../contrib/terminal/browser/terminalProcessExtHostProxy.js';
|
|
13
|
+
import { IEnvironmentVariableService } from '../../contrib/terminal/common/environmentVariable.js';
|
|
14
|
+
import { serializeEnvironmentVariableCollection, deserializeEnvironmentVariableCollection, deserializeEnvironmentDescriptionMap } from '../../../platform/terminal/common/environmentVariableShared.js';
|
|
15
|
+
import { ITerminalProfileResolverService, ITerminalProfileService } from '../../contrib/terminal/common/terminal.js';
|
|
16
|
+
import { IRemoteAgentService } from '../../services/remote/common/remoteAgentService.js';
|
|
17
|
+
import { withNullAsUndefined } from 'monaco-editor/esm/vs/base/common/types.js';
|
|
18
|
+
import { OS } from 'monaco-editor/esm/vs/base/common/platform.js';
|
|
19
|
+
import { Promises } from 'monaco-editor/esm/vs/base/common/async.js';
|
|
20
|
+
import { TerminalQuickFixType } from '../common/extHostTypes.js';
|
|
21
|
+
import { ITerminalLinkProviderService } from '../../contrib/terminalContrib/links/browser/links.js';
|
|
22
|
+
import { ITerminalQuickFixService } from '../../contrib/terminalContrib/quickFix/browser/quickFix.js';
|
|
23
|
+
let MainThreadTerminalService = class MainThreadTerminalService {
|
|
24
|
+
constructor(_extHostContext, _terminalService, _terminalLinkProviderService, _terminalQuickFixService, _instantiationService, _environmentVariableService, _logService, _terminalProfileResolverService, remoteAgentService, _terminalGroupService, _terminalEditorService, _terminalProfileService) {
|
|
25
|
+
this._extHostContext = _extHostContext;
|
|
26
|
+
this._terminalService = _terminalService;
|
|
27
|
+
this._terminalLinkProviderService = _terminalLinkProviderService;
|
|
28
|
+
this._terminalQuickFixService = _terminalQuickFixService;
|
|
29
|
+
this._instantiationService = _instantiationService;
|
|
30
|
+
this._environmentVariableService = _environmentVariableService;
|
|
31
|
+
this._logService = _logService;
|
|
32
|
+
this._terminalProfileResolverService = _terminalProfileResolverService;
|
|
33
|
+
this._terminalGroupService = _terminalGroupService;
|
|
34
|
+
this._terminalEditorService = _terminalEditorService;
|
|
35
|
+
this._terminalProfileService = _terminalProfileService;
|
|
36
|
+
this._extHostTerminals = ( new Map());
|
|
37
|
+
this._toDispose = ( new DisposableStore());
|
|
38
|
+
this._terminalProcessProxies = ( new Map());
|
|
39
|
+
this._profileProviders = ( new Map());
|
|
40
|
+
this._quickFixProviders = ( new Map());
|
|
41
|
+
this._os = OS;
|
|
42
|
+
this._proxy = ( _extHostContext.getProxy(ExtHostContext.ExtHostTerminalService));
|
|
43
|
+
this._toDispose.add(_terminalService.onDidCreateInstance((instance) => {
|
|
44
|
+
this._onTerminalOpened(instance);
|
|
45
|
+
this._onInstanceDimensionsChanged(instance);
|
|
46
|
+
}));
|
|
47
|
+
this._toDispose.add(_terminalService.onDidDisposeInstance(instance => this._onTerminalDisposed(instance)));
|
|
48
|
+
this._toDispose.add(_terminalService.onDidReceiveProcessId(instance => this._onTerminalProcessIdReady(instance)));
|
|
49
|
+
this._toDispose.add(_terminalService.onDidChangeInstanceDimensions(instance => this._onInstanceDimensionsChanged(instance)));
|
|
50
|
+
this._toDispose.add(_terminalService.onDidMaximumDimensionsChange(instance => this._onInstanceMaximumDimensionsChanged(instance)));
|
|
51
|
+
this._toDispose.add(_terminalService.onDidRequestStartExtensionTerminal(e => this._onRequestStartExtensionTerminal(e)));
|
|
52
|
+
this._toDispose.add(_terminalService.onDidChangeActiveInstance(instance => this._onActiveTerminalChanged(instance ? instance.instanceId : null)));
|
|
53
|
+
this._toDispose.add(_terminalService.onDidChangeInstanceTitle(instance => instance && this._onTitleChanged(instance.instanceId, instance.title)));
|
|
54
|
+
this._toDispose.add(_terminalService.onDidInputInstanceData(instance => this._proxy.$acceptTerminalInteraction(instance.instanceId)));
|
|
55
|
+
this._terminalService.instances.forEach(t => {
|
|
56
|
+
this._onTerminalOpened(t);
|
|
57
|
+
t.processReady.then(() => this._onTerminalProcessIdReady(t));
|
|
58
|
+
});
|
|
59
|
+
const activeInstance = this._terminalService.activeInstance;
|
|
60
|
+
if (activeInstance) {
|
|
61
|
+
this._proxy.$acceptActiveTerminalChanged(activeInstance.instanceId);
|
|
62
|
+
}
|
|
63
|
+
if (this._environmentVariableService.collections.size > 0) {
|
|
64
|
+
const collectionAsArray = [...this._environmentVariableService.collections.entries()];
|
|
65
|
+
const serializedCollections = ( collectionAsArray.map(e => {
|
|
66
|
+
return [e[0], serializeEnvironmentVariableCollection(e[1].map)];
|
|
67
|
+
}));
|
|
68
|
+
this._proxy.$initEnvironmentVariableCollections(serializedCollections);
|
|
69
|
+
}
|
|
70
|
+
remoteAgentService.getEnvironment().then(async (env) => {
|
|
71
|
+
this._os = env?.os || OS;
|
|
72
|
+
this._updateDefaultProfile();
|
|
73
|
+
});
|
|
74
|
+
this._terminalProfileService.onDidChangeAvailableProfiles(() => this._updateDefaultProfile());
|
|
75
|
+
}
|
|
76
|
+
dispose() {
|
|
77
|
+
this._toDispose.dispose();
|
|
78
|
+
this._linkProvider?.dispose();
|
|
79
|
+
}
|
|
80
|
+
async _updateDefaultProfile() {
|
|
81
|
+
const remoteAuthority = withNullAsUndefined(this._extHostContext.remoteAuthority);
|
|
82
|
+
const defaultProfile = this._terminalProfileResolverService.getDefaultProfile({ remoteAuthority, os: this._os });
|
|
83
|
+
const defaultAutomationProfile = this._terminalProfileResolverService.getDefaultProfile({ remoteAuthority, os: this._os, allowAutomationShell: true });
|
|
84
|
+
this._proxy.$acceptDefaultProfile(...(await Promise.all([defaultProfile, defaultAutomationProfile])));
|
|
85
|
+
}
|
|
86
|
+
async _getTerminalInstance(id) {
|
|
87
|
+
if (typeof id === 'string') {
|
|
88
|
+
return this._extHostTerminals.get(id);
|
|
89
|
+
}
|
|
90
|
+
return this._terminalService.getInstanceFromId(id);
|
|
91
|
+
}
|
|
92
|
+
async $createTerminal(extHostTerminalId, launchConfig) {
|
|
93
|
+
const shellLaunchConfig = {
|
|
94
|
+
name: launchConfig.name,
|
|
95
|
+
executable: launchConfig.shellPath,
|
|
96
|
+
args: launchConfig.shellArgs,
|
|
97
|
+
cwd: typeof launchConfig.cwd === 'string' ? launchConfig.cwd : URI.revive(launchConfig.cwd),
|
|
98
|
+
icon: launchConfig.icon,
|
|
99
|
+
color: launchConfig.color,
|
|
100
|
+
initialText: launchConfig.initialText,
|
|
101
|
+
waitOnExit: launchConfig.waitOnExit,
|
|
102
|
+
ignoreConfigurationCwd: true,
|
|
103
|
+
env: launchConfig.env,
|
|
104
|
+
strictEnv: launchConfig.strictEnv,
|
|
105
|
+
hideFromUser: launchConfig.hideFromUser,
|
|
106
|
+
customPtyImplementation: launchConfig.isExtensionCustomPtyTerminal
|
|
107
|
+
? (id, cols, rows) => ( new TerminalProcessExtHostProxy(id, cols, rows, this._terminalService))
|
|
108
|
+
: undefined,
|
|
109
|
+
extHostTerminalId,
|
|
110
|
+
isFeatureTerminal: launchConfig.isFeatureTerminal,
|
|
111
|
+
isExtensionOwnedTerminal: launchConfig.isExtensionOwnedTerminal,
|
|
112
|
+
useShellEnvironment: launchConfig.useShellEnvironment,
|
|
113
|
+
isTransient: launchConfig.isTransient
|
|
114
|
+
};
|
|
115
|
+
const terminal = Promises.withAsyncBody(async (r) => {
|
|
116
|
+
const terminal = await this._terminalService.createTerminal({
|
|
117
|
+
config: shellLaunchConfig,
|
|
118
|
+
location: await this._deserializeParentTerminal(launchConfig.location)
|
|
119
|
+
});
|
|
120
|
+
r(terminal);
|
|
121
|
+
});
|
|
122
|
+
this._extHostTerminals.set(extHostTerminalId, terminal);
|
|
123
|
+
const terminalInstance = await terminal;
|
|
124
|
+
this._toDispose.add(terminalInstance.onDisposed(() => {
|
|
125
|
+
this._extHostTerminals.delete(extHostTerminalId);
|
|
126
|
+
}));
|
|
127
|
+
}
|
|
128
|
+
async _deserializeParentTerminal(location) {
|
|
129
|
+
if (typeof location === 'object' && 'parentTerminal' in location) {
|
|
130
|
+
const parentTerminal = await this._extHostTerminals.get(( location.parentTerminal.toString()));
|
|
131
|
+
return parentTerminal ? { parentTerminal } : undefined;
|
|
132
|
+
}
|
|
133
|
+
return location;
|
|
134
|
+
}
|
|
135
|
+
async $show(id, preserveFocus) {
|
|
136
|
+
const terminalInstance = await this._getTerminalInstance(id);
|
|
137
|
+
if (terminalInstance) {
|
|
138
|
+
this._terminalService.setActiveInstance(terminalInstance);
|
|
139
|
+
if (terminalInstance.target === TerminalLocation.Editor) {
|
|
140
|
+
await this._terminalEditorService.revealActiveEditor(preserveFocus);
|
|
141
|
+
}
|
|
142
|
+
else {
|
|
143
|
+
await this._terminalGroupService.showPanel(!preserveFocus);
|
|
144
|
+
}
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
async $hide(id) {
|
|
148
|
+
const instanceToHide = await this._getTerminalInstance(id);
|
|
149
|
+
const activeInstance = this._terminalService.activeInstance;
|
|
150
|
+
if (activeInstance && activeInstance.instanceId === instanceToHide?.instanceId && activeInstance.target !== TerminalLocation.Editor) {
|
|
151
|
+
this._terminalGroupService.hidePanel();
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
async $dispose(id) {
|
|
155
|
+
(await this._getTerminalInstance(id))?.dispose(TerminalExitReason.Extension);
|
|
156
|
+
}
|
|
157
|
+
async $sendText(id, text, addNewLine) {
|
|
158
|
+
const instance = await this._getTerminalInstance(id);
|
|
159
|
+
await instance?.sendText(text, addNewLine);
|
|
160
|
+
}
|
|
161
|
+
$sendProcessExit(terminalId, exitCode) {
|
|
162
|
+
this._terminalProcessProxies.get(terminalId)?.emitExit(exitCode);
|
|
163
|
+
}
|
|
164
|
+
$startSendingDataEvents() {
|
|
165
|
+
if (!this._dataEventTracker) {
|
|
166
|
+
this._dataEventTracker = this._instantiationService.createInstance(TerminalDataEventTracker, (id, data) => {
|
|
167
|
+
this._onTerminalData(id, data);
|
|
168
|
+
});
|
|
169
|
+
this._terminalService.instances.forEach(t => {
|
|
170
|
+
t.initialDataEvents?.forEach(d => this._onTerminalData(t.instanceId, d));
|
|
171
|
+
});
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
$stopSendingDataEvents() {
|
|
175
|
+
this._dataEventTracker?.dispose();
|
|
176
|
+
this._dataEventTracker = undefined;
|
|
177
|
+
}
|
|
178
|
+
$startLinkProvider() {
|
|
179
|
+
this._linkProvider?.dispose();
|
|
180
|
+
this._linkProvider = this._terminalLinkProviderService.registerLinkProvider(( new ExtensionTerminalLinkProvider(this._proxy)));
|
|
181
|
+
}
|
|
182
|
+
$stopLinkProvider() {
|
|
183
|
+
this._linkProvider?.dispose();
|
|
184
|
+
this._linkProvider = undefined;
|
|
185
|
+
}
|
|
186
|
+
$registerProcessSupport(isSupported) {
|
|
187
|
+
this._terminalService.registerProcessSupport(isSupported);
|
|
188
|
+
}
|
|
189
|
+
$registerProfileProvider(id, extensionIdentifier) {
|
|
190
|
+
this._profileProviders.set(id, this._terminalProfileService.registerTerminalProfileProvider(extensionIdentifier, id, {
|
|
191
|
+
createContributedTerminalProfile: async (options) => {
|
|
192
|
+
return this._proxy.$createContributedProfileTerminal(id, options);
|
|
193
|
+
}
|
|
194
|
+
}));
|
|
195
|
+
}
|
|
196
|
+
$unregisterProfileProvider(id) {
|
|
197
|
+
this._profileProviders.get(id)?.dispose();
|
|
198
|
+
this._profileProviders.delete(id);
|
|
199
|
+
}
|
|
200
|
+
async $registerQuickFixProvider(id, extensionId) {
|
|
201
|
+
this._quickFixProviders.set(id, this._terminalQuickFixService.registerQuickFixProvider(id, {
|
|
202
|
+
provideTerminalQuickFixes: async (terminalCommand, lines, option, token) => {
|
|
203
|
+
if (token.isCancellationRequested) {
|
|
204
|
+
return;
|
|
205
|
+
}
|
|
206
|
+
if (option.outputMatcher?.length && option.outputMatcher.length > 40) {
|
|
207
|
+
option.outputMatcher.length = 40;
|
|
208
|
+
this._logService.warn('Cannot exceed output matcher length of 40');
|
|
209
|
+
}
|
|
210
|
+
const commandLineMatch = terminalCommand.command.match(option.commandLineMatcher);
|
|
211
|
+
if (!commandLineMatch) {
|
|
212
|
+
return;
|
|
213
|
+
}
|
|
214
|
+
const outputMatcher = option.outputMatcher;
|
|
215
|
+
let outputMatch;
|
|
216
|
+
if (outputMatcher) {
|
|
217
|
+
outputMatch = getOutputMatchForLines(lines, outputMatcher);
|
|
218
|
+
}
|
|
219
|
+
if (!outputMatch) {
|
|
220
|
+
return;
|
|
221
|
+
}
|
|
222
|
+
const matchResult = { commandLineMatch, outputMatch, commandLine: terminalCommand.command };
|
|
223
|
+
if (matchResult) {
|
|
224
|
+
const result = await this._proxy.$provideTerminalQuickFixes(id, matchResult, token);
|
|
225
|
+
if (result && Array.isArray(result)) {
|
|
226
|
+
return ( result.map(r => parseQuickFix(id, extensionId, r)));
|
|
227
|
+
}
|
|
228
|
+
else if (result) {
|
|
229
|
+
return parseQuickFix(id, extensionId, result);
|
|
230
|
+
}
|
|
231
|
+
}
|
|
232
|
+
return;
|
|
233
|
+
}
|
|
234
|
+
}));
|
|
235
|
+
}
|
|
236
|
+
$unregisterQuickFixProvider(id) {
|
|
237
|
+
this._quickFixProviders.get(id)?.dispose();
|
|
238
|
+
this._quickFixProviders.delete(id);
|
|
239
|
+
}
|
|
240
|
+
_onActiveTerminalChanged(terminalId) {
|
|
241
|
+
this._proxy.$acceptActiveTerminalChanged(terminalId);
|
|
242
|
+
}
|
|
243
|
+
_onTerminalData(terminalId, data) {
|
|
244
|
+
this._proxy.$acceptTerminalProcessData(terminalId, data);
|
|
245
|
+
}
|
|
246
|
+
_onTitleChanged(terminalId, name) {
|
|
247
|
+
this._proxy.$acceptTerminalTitleChange(terminalId, name);
|
|
248
|
+
}
|
|
249
|
+
_onTerminalDisposed(terminalInstance) {
|
|
250
|
+
this._proxy.$acceptTerminalClosed(terminalInstance.instanceId, terminalInstance.exitCode, terminalInstance.exitReason ?? TerminalExitReason.Unknown);
|
|
251
|
+
}
|
|
252
|
+
_onTerminalOpened(terminalInstance) {
|
|
253
|
+
const extHostTerminalId = terminalInstance.shellLaunchConfig.extHostTerminalId;
|
|
254
|
+
const shellLaunchConfigDto = {
|
|
255
|
+
name: terminalInstance.shellLaunchConfig.name,
|
|
256
|
+
executable: terminalInstance.shellLaunchConfig.executable,
|
|
257
|
+
args: terminalInstance.shellLaunchConfig.args,
|
|
258
|
+
cwd: terminalInstance.shellLaunchConfig.cwd,
|
|
259
|
+
env: terminalInstance.shellLaunchConfig.env,
|
|
260
|
+
hideFromUser: terminalInstance.shellLaunchConfig.hideFromUser
|
|
261
|
+
};
|
|
262
|
+
this._proxy.$acceptTerminalOpened(terminalInstance.instanceId, extHostTerminalId, terminalInstance.title, shellLaunchConfigDto);
|
|
263
|
+
}
|
|
264
|
+
_onTerminalProcessIdReady(terminalInstance) {
|
|
265
|
+
if (terminalInstance.processId === undefined) {
|
|
266
|
+
return;
|
|
267
|
+
}
|
|
268
|
+
this._proxy.$acceptTerminalProcessId(terminalInstance.instanceId, terminalInstance.processId);
|
|
269
|
+
}
|
|
270
|
+
_onInstanceDimensionsChanged(instance) {
|
|
271
|
+
this._proxy.$acceptTerminalDimensions(instance.instanceId, instance.cols, instance.rows);
|
|
272
|
+
}
|
|
273
|
+
_onInstanceMaximumDimensionsChanged(instance) {
|
|
274
|
+
this._proxy.$acceptTerminalMaximumDimensions(instance.instanceId, instance.maxCols, instance.maxRows);
|
|
275
|
+
}
|
|
276
|
+
_onRequestStartExtensionTerminal(request) {
|
|
277
|
+
const proxy = request.proxy;
|
|
278
|
+
this._terminalProcessProxies.set(proxy.instanceId, proxy);
|
|
279
|
+
const initialDimensions = request.cols && request.rows ? {
|
|
280
|
+
columns: request.cols,
|
|
281
|
+
rows: request.rows
|
|
282
|
+
} : undefined;
|
|
283
|
+
this._proxy.$startExtensionTerminal(proxy.instanceId, initialDimensions).then(request.callback);
|
|
284
|
+
proxy.onInput(data => this._proxy.$acceptProcessInput(proxy.instanceId, data));
|
|
285
|
+
proxy.onShutdown(immediate => this._proxy.$acceptProcessShutdown(proxy.instanceId, immediate));
|
|
286
|
+
proxy.onRequestCwd(() => this._proxy.$acceptProcessRequestCwd(proxy.instanceId));
|
|
287
|
+
proxy.onRequestInitialCwd(() => this._proxy.$acceptProcessRequestInitialCwd(proxy.instanceId));
|
|
288
|
+
proxy.onRequestLatency(() => this._onRequestLatency(proxy.instanceId));
|
|
289
|
+
}
|
|
290
|
+
$sendProcessData(terminalId, data) {
|
|
291
|
+
this._terminalProcessProxies.get(terminalId)?.emitData(data);
|
|
292
|
+
}
|
|
293
|
+
$sendProcessReady(terminalId, pid, cwd) {
|
|
294
|
+
this._terminalProcessProxies.get(terminalId)?.emitReady(pid, cwd);
|
|
295
|
+
}
|
|
296
|
+
$sendProcessProperty(terminalId, property) {
|
|
297
|
+
if (property.type === "title" ) {
|
|
298
|
+
const instance = this._terminalService.getInstanceFromId(terminalId);
|
|
299
|
+
instance?.rename(property.value);
|
|
300
|
+
}
|
|
301
|
+
this._terminalProcessProxies.get(terminalId)?.emitProcessProperty(property);
|
|
302
|
+
}
|
|
303
|
+
async _onRequestLatency(terminalId) {
|
|
304
|
+
const COUNT = 2;
|
|
305
|
+
let sum = 0;
|
|
306
|
+
for (let i = 0; i < COUNT; i++) {
|
|
307
|
+
const sw = StopWatch.create(true);
|
|
308
|
+
await this._proxy.$acceptProcessRequestLatency(terminalId);
|
|
309
|
+
sw.stop();
|
|
310
|
+
sum += sw.elapsed();
|
|
311
|
+
}
|
|
312
|
+
this._getTerminalProcess(terminalId)?.emitLatency(sum / COUNT);
|
|
313
|
+
}
|
|
314
|
+
_getTerminalProcess(terminalId) {
|
|
315
|
+
const terminal = this._terminalProcessProxies.get(terminalId);
|
|
316
|
+
if (!terminal) {
|
|
317
|
+
this._logService.error(`Unknown terminal: ${terminalId}`);
|
|
318
|
+
return undefined;
|
|
319
|
+
}
|
|
320
|
+
return terminal;
|
|
321
|
+
}
|
|
322
|
+
$setEnvironmentVariableCollection(extensionIdentifier, persistent, collection, descriptionMap) {
|
|
323
|
+
if (collection) {
|
|
324
|
+
const translatedCollection = {
|
|
325
|
+
persistent,
|
|
326
|
+
map: deserializeEnvironmentVariableCollection(collection),
|
|
327
|
+
descriptionMap: deserializeEnvironmentDescriptionMap(descriptionMap)
|
|
328
|
+
};
|
|
329
|
+
this._environmentVariableService.set(extensionIdentifier, translatedCollection);
|
|
330
|
+
}
|
|
331
|
+
else {
|
|
332
|
+
this._environmentVariableService.delete(extensionIdentifier);
|
|
333
|
+
}
|
|
334
|
+
}
|
|
335
|
+
};
|
|
336
|
+
MainThreadTerminalService = __decorate([
|
|
337
|
+
extHostNamedCustomer(MainContext.MainThreadTerminalService),
|
|
338
|
+
( __param(1, ITerminalService)),
|
|
339
|
+
( __param(2, ITerminalLinkProviderService)),
|
|
340
|
+
( __param(3, ITerminalQuickFixService)),
|
|
341
|
+
( __param(4, IInstantiationService)),
|
|
342
|
+
( __param(5, IEnvironmentVariableService)),
|
|
343
|
+
( __param(6, ILogService)),
|
|
344
|
+
( __param(7, ITerminalProfileResolverService)),
|
|
345
|
+
( __param(8, IRemoteAgentService)),
|
|
346
|
+
( __param(9, ITerminalGroupService)),
|
|
347
|
+
( __param(10, ITerminalEditorService)),
|
|
348
|
+
( __param(11, ITerminalProfileService))
|
|
349
|
+
], MainThreadTerminalService);
|
|
350
|
+
let TerminalDataEventTracker = class TerminalDataEventTracker extends Disposable {
|
|
351
|
+
constructor(_callback, _terminalService) {
|
|
352
|
+
super();
|
|
353
|
+
this._callback = _callback;
|
|
354
|
+
this._terminalService = _terminalService;
|
|
355
|
+
this._register(this._bufferer = ( new TerminalDataBufferer(this._callback)));
|
|
356
|
+
this._terminalService.instances.forEach(instance => this._registerInstance(instance));
|
|
357
|
+
this._register(this._terminalService.onDidCreateInstance(instance => this._registerInstance(instance)));
|
|
358
|
+
this._register(this._terminalService.onDidDisposeInstance(instance => this._bufferer.stopBuffering(instance.instanceId)));
|
|
359
|
+
}
|
|
360
|
+
_registerInstance(instance) {
|
|
361
|
+
this._register(this._bufferer.startBuffering(instance.instanceId, instance.onData));
|
|
362
|
+
}
|
|
363
|
+
};
|
|
364
|
+
TerminalDataEventTracker = ( __decorate([
|
|
365
|
+
( __param(1, ITerminalService))
|
|
366
|
+
], TerminalDataEventTracker));
|
|
367
|
+
class ExtensionTerminalLinkProvider {
|
|
368
|
+
constructor(_proxy) {
|
|
369
|
+
this._proxy = _proxy;
|
|
370
|
+
}
|
|
371
|
+
async provideLinks(instance, line) {
|
|
372
|
+
const proxy = this._proxy;
|
|
373
|
+
const extHostLinks = await proxy.$provideLinks(instance.instanceId, line);
|
|
374
|
+
return ( extHostLinks.map(dto => ({
|
|
375
|
+
id: dto.id,
|
|
376
|
+
startIndex: dto.startIndex,
|
|
377
|
+
length: dto.length,
|
|
378
|
+
label: dto.label,
|
|
379
|
+
activate: () => proxy.$activateLink(instance.instanceId, dto.id)
|
|
380
|
+
})));
|
|
381
|
+
}
|
|
382
|
+
}
|
|
383
|
+
function getOutputMatchForLines(lines, outputMatcher) {
|
|
384
|
+
const match = lines.join('\n').match(outputMatcher.lineMatcher);
|
|
385
|
+
return match ? { regexMatch: match, outputLines: lines } : undefined;
|
|
386
|
+
}
|
|
387
|
+
function parseQuickFix(id, source, fix) {
|
|
388
|
+
let type = TerminalQuickFixType.Command;
|
|
389
|
+
if ('uri' in fix) {
|
|
390
|
+
fix.uri = URI.revive(fix.uri);
|
|
391
|
+
type = TerminalQuickFixType.Opener;
|
|
392
|
+
}
|
|
393
|
+
return { id, type, source, ...fix };
|
|
394
|
+
}
|
|
395
|
+
export { MainThreadTerminalService, getOutputMatchForLines };
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { __decorate, __param } from '../../../../../node_modules/tslib/tslib.es6.js';
|
|
2
|
+
import { ExtHostContext, MainContext } from '../common/extHost.protocol.js';
|
|
3
|
+
import { extHostNamedCustomer } from '../../services/extensions/common/extHostCustomers.js';
|
|
4
|
+
import { IThemeService } from 'monaco-editor/esm/vs/platform/theme/common/themeService.js';
|
|
5
|
+
let MainThreadTheming = class MainThreadTheming {
|
|
6
|
+
constructor(extHostContext, themeService) {
|
|
7
|
+
this._themeService = themeService;
|
|
8
|
+
this._proxy = ( extHostContext.getProxy(ExtHostContext.ExtHostTheming));
|
|
9
|
+
this._themeChangeListener = this._themeService.onDidColorThemeChange(e => {
|
|
10
|
+
this._proxy.$onColorThemeChange(this._themeService.getColorTheme().type);
|
|
11
|
+
});
|
|
12
|
+
this._proxy.$onColorThemeChange(this._themeService.getColorTheme().type);
|
|
13
|
+
}
|
|
14
|
+
dispose() {
|
|
15
|
+
this._themeChangeListener.dispose();
|
|
16
|
+
}
|
|
17
|
+
};
|
|
18
|
+
MainThreadTheming = __decorate([
|
|
19
|
+
extHostNamedCustomer(MainContext.MainThreadTheming),
|
|
20
|
+
( __param(1, IThemeService))
|
|
21
|
+
], MainThreadTheming);
|
|
22
|
+
export { MainThreadTheming };
|