From 82f82c954d072bceb2500a5646bde872089c3278 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Wed, 16 Nov 2016 15:03:57 +0100 Subject: [PATCH] move resolverService to vs/editor/common/services (for #15558) --- src/vs/editor/browser/standalone/simpleServices.ts | 2 +- src/vs/editor/browser/standalone/standaloneEditor.ts | 2 +- src/vs/editor/common/services/bulkEdit.ts | 2 +- .../resolver.ts => editor/common/services/resolverService.ts} | 0 .../editor/contrib/goToDeclaration/browser/goToDeclaration.ts | 2 +- .../contrib/referenceSearch/browser/referencesController.ts | 2 +- .../editor/contrib/referenceSearch/browser/referencesModel.ts | 2 +- .../editor/contrib/referenceSearch/browser/referencesWidget.ts | 2 +- src/vs/editor/contrib/rename/browser/rename.ts | 2 +- src/vs/test/utils/servicesTestUtils.ts | 2 +- src/vs/workbench/api/node/mainThreadDocuments.ts | 2 +- src/vs/workbench/api/node/mainThreadWorkspace.ts | 2 +- src/vs/workbench/common/editor/resourceEditorInput.ts | 2 +- src/vs/workbench/electron-browser/workbench.ts | 2 +- .../contentprovider/common/contentprovider.contribution.ts | 2 +- src/vs/workbench/parts/files/browser/saveErrorHandler.ts | 2 +- src/vs/workbench/parts/html/browser/html.contribution.ts | 2 +- src/vs/workbench/parts/html/browser/htmlPreviewPart.ts | 2 +- src/vs/workbench/parts/search/browser/replaceService.ts | 2 +- .../textmodelResolver/common/textModelResolverService.ts | 2 +- .../textmodelResolver/test/textModelResolverService.test.ts | 2 +- 21 files changed, 20 insertions(+), 20 deletions(-) rename src/vs/{platform/textmodelResolver/common/resolver.ts => editor/common/services/resolverService.ts} (100%) diff --git a/src/vs/editor/browser/standalone/simpleServices.ts b/src/vs/editor/browser/standalone/simpleServices.ts index 16c4c979613..601388feff8 100644 --- a/src/vs/editor/browser/standalone/simpleServices.ts +++ b/src/vs/editor/browser/standalone/simpleServices.ts @@ -26,7 +26,7 @@ import { getDefaultValues as getDefaultConfiguration } from 'vs/platform/configu import { CommandService } from 'vs/platform/commands/common/commandService'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { IProgressService, IProgressRunner } from 'vs/platform/progress/common/progress'; -import { ITextModelResolverService, ITextModelContentProvider } from 'vs/platform/textmodelResolver/common/resolver'; +import { ITextModelResolverService, ITextModelContentProvider } from 'vs/editor/common/services/resolverService'; import { IDisposable } from 'vs/base/common/lifecycle'; export class SimpleEditor implements IEditor { diff --git a/src/vs/editor/browser/standalone/standaloneEditor.ts b/src/vs/editor/browser/standalone/standaloneEditor.ts index 32b24183e46..48296734e6f 100644 --- a/src/vs/editor/browser/standalone/standaloneEditor.ts +++ b/src/vs/editor/browser/standalone/standaloneEditor.ts @@ -32,7 +32,7 @@ import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { IContextKeyService } from 'vs/platform/contextkey/common/contextkey'; import { ICodeEditorService } from 'vs/editor/common/services/codeEditorService'; import { IEditorWorkerService } from 'vs/editor/common/services/editorWorkerService'; -import { ITextModelResolverService } from 'vs/platform/textmodelResolver/common/resolver'; +import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; /** * @internal diff --git a/src/vs/editor/common/services/bulkEdit.ts b/src/vs/editor/common/services/bulkEdit.ts index 36045eaacca..4dc674d4e5d 100644 --- a/src/vs/editor/common/services/bulkEdit.ts +++ b/src/vs/editor/common/services/bulkEdit.ts @@ -9,7 +9,7 @@ import { merge } from 'vs/base/common/arrays'; import { IStringDictionary, forEach, values } from 'vs/base/common/collections'; import URI from 'vs/base/common/uri'; import { TPromise } from 'vs/base/common/winjs.base'; -import { ITextModelResolverService } from 'vs/platform/textmodelResolver/common/resolver'; +import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; import { IEventService } from 'vs/platform/event/common/event'; import { EventType as FileEventType, FileChangesEvent, IFileChange } from 'vs/platform/files/common/files'; import { EditOperation } from 'vs/editor/common/core/editOperation'; diff --git a/src/vs/platform/textmodelResolver/common/resolver.ts b/src/vs/editor/common/services/resolverService.ts similarity index 100% rename from src/vs/platform/textmodelResolver/common/resolver.ts rename to src/vs/editor/common/services/resolverService.ts diff --git a/src/vs/editor/contrib/goToDeclaration/browser/goToDeclaration.ts b/src/vs/editor/contrib/goToDeclaration/browser/goToDeclaration.ts index cd71f592581..882e1b798f6 100644 --- a/src/vs/editor/contrib/goToDeclaration/browser/goToDeclaration.ts +++ b/src/vs/editor/contrib/goToDeclaration/browser/goToDeclaration.ts @@ -32,7 +32,7 @@ import { ReferencesModel } from 'vs/editor/contrib/referenceSearch/browser/refer import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { PeekContext } from 'vs/editor/contrib/zoneWidget/browser/peekViewWidget'; import { ContextKeyExpr } from 'vs/platform/contextkey/common/contextkey'; -import { ITextModelResolverService } from 'vs/platform/textmodelResolver/common/resolver'; +import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; import ModeContextKeys = editorCommon.ModeContextKeys; import EditorContextKeys = editorCommon.EditorContextKeys; diff --git a/src/vs/editor/contrib/referenceSearch/browser/referencesController.ts b/src/vs/editor/contrib/referenceSearch/browser/referencesController.ts index 173ff1ed5e7..50e9720009c 100644 --- a/src/vs/editor/contrib/referenceSearch/browser/referencesController.ts +++ b/src/vs/editor/contrib/referenceSearch/browser/referencesController.ts @@ -25,7 +25,7 @@ import { IPeekViewService } from 'vs/editor/contrib/zoneWidget/browser/peekViewW import { ReferencesModel, OneReference } from './referencesModel'; import { ReferenceWidget, LayoutData } from './referencesWidget'; import { Range } from 'vs/editor/common/core/range'; -import { ITextModelResolverService } from 'vs/platform/textmodelResolver/common/resolver'; +import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; export const ctxReferenceSearchVisible = new RawContextKey('referenceSearchVisible', false); diff --git a/src/vs/editor/contrib/referenceSearch/browser/referencesModel.ts b/src/vs/editor/contrib/referenceSearch/browser/referencesModel.ts index 08bdb6ba950..76db5789f2b 100644 --- a/src/vs/editor/contrib/referenceSearch/browser/referencesModel.ts +++ b/src/vs/editor/contrib/referenceSearch/browser/referencesModel.ts @@ -14,7 +14,7 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { Range } from 'vs/editor/common/core/range'; import { IModel, IPosition, IRange } from 'vs/editor/common/editorCommon'; import { Location } from 'vs/editor/common/modes'; -import { ITextModelResolverService } from 'vs/platform/textmodelResolver/common/resolver'; +import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; export class OneReference { diff --git a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts index 8e06439ef2e..da509cfb6c3 100644 --- a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts +++ b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts @@ -37,7 +37,7 @@ import { ICodeEditor } from 'vs/editor/browser/editorBrowser'; import { EmbeddedCodeEditorWidget } from 'vs/editor/browser/widget/embeddedCodeEditorWidget'; import { PeekViewWidget, IPeekViewService } from 'vs/editor/contrib/zoneWidget/browser/peekViewWidget'; import { FileReferences, OneReference, ReferencesModel } from './referencesModel'; -import { ITextModelResolverService } from 'vs/platform/textmodelResolver/common/resolver'; +import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; class DecorationsManager implements IDisposable { diff --git a/src/vs/editor/contrib/rename/browser/rename.ts b/src/vs/editor/contrib/rename/browser/rename.ts index 3ac12299540..570811ad5e8 100644 --- a/src/vs/editor/contrib/rename/browser/rename.ts +++ b/src/vs/editor/contrib/rename/browser/rename.ts @@ -21,7 +21,7 @@ import { BulkEdit, createBulkEdit } from 'vs/editor/common/services/bulkEdit'; import { ICodeEditor } from 'vs/editor/browser/editorBrowser'; import { rename } from '../common/rename'; import RenameInputField from './renameInputField'; -import { ITextModelResolverService } from 'vs/platform/textmodelResolver/common/resolver'; +import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; // --- register actions and commands diff --git a/src/vs/test/utils/servicesTestUtils.ts b/src/vs/test/utils/servicesTestUtils.ts index 5d06d27add1..c8e37632912 100644 --- a/src/vs/test/utils/servicesTestUtils.ts +++ b/src/vs/test/utils/servicesTestUtils.ts @@ -24,7 +24,7 @@ import { IStorageService, StorageScope } from 'vs/platform/storage/common/storag import { IQuickOpenService } from 'vs/workbench/services/quickopen/common/quickOpenService'; import { IPartService } from 'vs/workbench/services/part/common/partService'; import { TextModelResolverService } from 'vs/workbench/services/textmodelResolver/common/textModelResolverService'; -import { ITextModelResolverService } from 'vs/platform/textmodelResolver/common/resolver'; +import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; import { IEditorInput, IEditorOptions, Position, Direction, IEditor, IResourceInput } from 'vs/platform/editor/common/editor'; import { IEventService } from 'vs/platform/event/common/event'; import { IUntitledEditorService, UntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; diff --git a/src/vs/workbench/api/node/mainThreadDocuments.ts b/src/vs/workbench/api/node/mainThreadDocuments.ts index 17f6e3f9f6c..8a575e652df 100644 --- a/src/vs/workbench/api/node/mainThreadDocuments.ts +++ b/src/vs/workbench/api/node/mainThreadDocuments.ts @@ -20,7 +20,7 @@ import { IFileService } from 'vs/platform/files/common/files'; import { IModeService } from 'vs/editor/common/services/modeService'; import { IUntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; import { ExtHostContext, MainThreadDocumentsShape, ExtHostDocumentsShape } from './extHost.protocol'; -import { ITextModelResolverService } from 'vs/platform/textmodelResolver/common/resolver'; +import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; export class MainThreadDocuments extends MainThreadDocumentsShape { private _modelService: IModelService; diff --git a/src/vs/workbench/api/node/mainThreadWorkspace.ts b/src/vs/workbench/api/node/mainThreadWorkspace.ts index ca48df3618e..65a400804a5 100644 --- a/src/vs/workbench/api/node/mainThreadWorkspace.ts +++ b/src/vs/workbench/api/node/mainThreadWorkspace.ts @@ -15,7 +15,7 @@ import { bulkEdit, IResourceEdit } from 'vs/editor/common/services/bulkEdit'; import { TPromise } from 'vs/base/common/winjs.base'; import { Uri } from 'vscode'; import { MainThreadWorkspaceShape } from './extHost.protocol'; -import { ITextModelResolverService } from 'vs/platform/textmodelResolver/common/resolver'; +import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; export class MainThreadWorkspace extends MainThreadWorkspaceShape { diff --git a/src/vs/workbench/common/editor/resourceEditorInput.ts b/src/vs/workbench/common/editor/resourceEditorInput.ts index a6236d37356..5464bb982f9 100644 --- a/src/vs/workbench/common/editor/resourceEditorInput.ts +++ b/src/vs/workbench/common/editor/resourceEditorInput.ts @@ -8,7 +8,7 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { EditorInput, ITextEditorModel } from 'vs/workbench/common/editor'; import URI from 'vs/base/common/uri'; import { telemetryURIDescriptor } from 'vs/platform/telemetry/common/telemetry'; -import { ITextModelResolverService } from 'vs/platform/textmodelResolver/common/resolver'; +import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; import { ResourceEditorModel } from 'vs/workbench/common/editor/resourceEditorModel'; /** diff --git a/src/vs/workbench/electron-browser/workbench.ts b/src/vs/workbench/electron-browser/workbench.ts index 32ce54e7136..d31d414060a 100644 --- a/src/vs/workbench/electron-browser/workbench.ts +++ b/src/vs/workbench/electron-browser/workbench.ts @@ -77,7 +77,7 @@ import { SyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; import { TextFileService } from 'vs/workbench/services/textfile/electron-browser/textFileService'; import { ITextFileService } from 'vs/workbench/services/textfile/common/textfiles'; import { TextModelResolverService } from 'vs/workbench/services/textmodelResolver/common/textModelResolverService'; -import { ITextModelResolverService } from 'vs/platform/textmodelResolver/common/resolver'; +import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; import { ServiceCollection } from 'vs/platform/instantiation/common/serviceCollection'; import { ILifecycleService } from 'vs/platform/lifecycle/common/lifecycle'; import { IMessageService } from 'vs/platform/message/common/message'; diff --git a/src/vs/workbench/parts/contentprovider/common/contentprovider.contribution.ts b/src/vs/workbench/parts/contentprovider/common/contentprovider.contribution.ts index 34bab8f57eb..5b670012d12 100644 --- a/src/vs/workbench/parts/contentprovider/common/contentprovider.contribution.ts +++ b/src/vs/workbench/parts/contentprovider/common/contentprovider.contribution.ts @@ -12,7 +12,7 @@ import { IModel } from 'vs/editor/common/editorCommon'; import JSONContributionRegistry = require('vs/platform/jsonschemas/common/jsonContributionRegistry'); import { Registry } from 'vs/platform/platform'; import { IWorkbenchContribution, IWorkbenchContributionsRegistry, Extensions as WorkbenchExtensions } from 'vs/workbench/common/contributions'; -import { ITextModelResolverService } from 'vs/platform/textmodelResolver/common/resolver'; +import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; let schemaRegistry = Registry.as(JSONContributionRegistry.Extensions.JSONContribution); diff --git a/src/vs/workbench/parts/files/browser/saveErrorHandler.ts b/src/vs/workbench/parts/files/browser/saveErrorHandler.ts index 50d18741538..31ea4662869 100644 --- a/src/vs/workbench/parts/files/browser/saveErrorHandler.ts +++ b/src/vs/workbench/parts/files/browser/saveErrorHandler.ts @@ -29,7 +29,7 @@ import { IModelService } from 'vs/editor/common/services/modelService'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { IWorkbenchContribution } from 'vs/workbench/common/contributions'; import { TextFileEditorModel } from 'vs/workbench/services/textfile/common/textFileEditorModel'; -import { ITextModelResolverService } from 'vs/platform/textmodelResolver/common/resolver'; +import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; // A handler for save error happening with conflict resolution actions export class SaveErrorHandler implements ISaveErrorHandler, IWorkbenchContribution { diff --git a/src/vs/workbench/parts/html/browser/html.contribution.ts b/src/vs/workbench/parts/html/browser/html.contribution.ts index b4bc3c3113f..d180703b029 100644 --- a/src/vs/workbench/parts/html/browser/html.contribution.ts +++ b/src/vs/workbench/parts/html/browser/html.contribution.ts @@ -19,7 +19,7 @@ import { SyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import { isCommonCodeEditor, ICommonCodeEditor, IModel } from 'vs/editor/common/editorCommon'; import { HtmlZoneController } from './htmlEditorZone'; -import { ITextModelResolverService } from 'vs/platform/textmodelResolver/common/resolver'; +import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; // --- Register Editor (Registry.as(EditorExtensions.Editors)).registerEditor(new EditorDescriptor(HtmlPreviewPart.ID, diff --git a/src/vs/workbench/parts/html/browser/htmlPreviewPart.ts b/src/vs/workbench/parts/html/browser/htmlPreviewPart.ts index ffea4d6a337..3e6685df189 100644 --- a/src/vs/workbench/parts/html/browser/htmlPreviewPart.ts +++ b/src/vs/workbench/parts/html/browser/htmlPreviewPart.ts @@ -20,7 +20,7 @@ import { BaseTextEditorModel } from 'vs/workbench/common/editor/textEditorModel' import { HtmlInput } from 'vs/workbench/parts/html/common/htmlInput'; import { IThemeService } from 'vs/workbench/services/themes/common/themeService'; import { IOpenerService } from 'vs/platform/opener/common/opener'; -import { ITextModelResolverService } from 'vs/platform/textmodelResolver/common/resolver'; +import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; import Webview from './webview'; /** diff --git a/src/vs/workbench/parts/search/browser/replaceService.ts b/src/vs/workbench/parts/search/browser/replaceService.ts index 93ff400d0ab..518ad4d0453 100644 --- a/src/vs/workbench/parts/search/browser/replaceService.ts +++ b/src/vs/workbench/parts/search/browser/replaceService.ts @@ -21,7 +21,7 @@ import { IProgressRunner } from 'vs/platform/progress/common/progress'; import { IDiffEditor } from 'vs/editor/browser/editorBrowser'; import { DiffEditorInput } from 'vs/workbench/common/editor/diffEditorInput'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; -import { ITextModelResolverService } from 'vs/platform/textmodelResolver/common/resolver'; +import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; class EditorInputCache { diff --git a/src/vs/workbench/services/textmodelResolver/common/textModelResolverService.ts b/src/vs/workbench/services/textmodelResolver/common/textModelResolverService.ts index ee023c0cffe..aad206e758d 100644 --- a/src/vs/workbench/services/textmodelResolver/common/textModelResolverService.ts +++ b/src/vs/workbench/services/textmodelResolver/common/textModelResolverService.ts @@ -15,7 +15,7 @@ import { sequence } from 'vs/base/common/async'; import { ResourceEditorModel } from 'vs/workbench/common/editor/resourceEditorModel'; import { ITextFileService } from 'vs/workbench/services/textfile/common/textfiles'; import network = require('vs/base/common/network'); -import { ITextModelResolverService, ITextModelContentProvider } from 'vs/platform/textmodelResolver/common/resolver'; +import { ITextModelResolverService, ITextModelContentProvider } from 'vs/editor/common/services/resolverService'; import { IUntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; import { UntitledEditorInput } from 'vs/workbench/common/editor/untitledEditorInput'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; diff --git a/src/vs/workbench/services/textmodelResolver/test/textModelResolverService.test.ts b/src/vs/workbench/services/textmodelResolver/test/textModelResolverService.test.ts index 8cf824d6098..5f09abac3ae 100644 --- a/src/vs/workbench/services/textmodelResolver/test/textModelResolverService.test.ts +++ b/src/vs/workbench/services/textmodelResolver/test/textModelResolverService.test.ts @@ -13,7 +13,7 @@ import { ResourceEditorInput } from 'vs/workbench/common/editor/resourceEditorIn import { ResourceEditorModel } from 'vs/workbench/common/editor/resourceEditorModel'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { workbenchInstantiationService, TestTextFileService, toResource } from 'vs/test/utils/servicesTestUtils'; -import { ITextModelResolverService } from 'vs/platform/textmodelResolver/common/resolver'; +import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; import { IModelService } from 'vs/editor/common/services/modelService'; import { IModeService } from 'vs/editor/common/services/modeService'; import { TextFileEditorModel } from 'vs/workbench/services/textfile/common/textFileEditorModel'; -- GitLab