mirror of
https://github.com/Microsoft/vscode
synced 2024-09-13 21:55:38 +00:00
add IEnv service to standalone services
This commit is contained in:
parent
6d45c3610a
commit
e8906f0bd2
|
@ -91,6 +91,7 @@ import { AudioCue, IAudioCueService, Sound } from 'vs/platform/audioCues/browser
|
||||||
import { LogService } from 'vs/platform/log/common/logService';
|
import { LogService } from 'vs/platform/log/common/logService';
|
||||||
import { getEditorFeatures } from 'vs/editor/common/editorFeatures';
|
import { getEditorFeatures } from 'vs/editor/common/editorFeatures';
|
||||||
import { onUnexpectedError } from 'vs/base/common/errors';
|
import { onUnexpectedError } from 'vs/base/common/errors';
|
||||||
|
import { ExtensionKind, IEnvironmentService, IExtensionHostDebugParams } from 'vs/platform/environment/common/environment';
|
||||||
|
|
||||||
class SimpleModel implements IResolvedTextEditorModel {
|
class SimpleModel implements IResolvedTextEditorModel {
|
||||||
|
|
||||||
|
@ -201,6 +202,39 @@ class StandaloneProgressService implements IProgressService {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
class StandaloneEnvironmentService implements IEnvironmentService {
|
||||||
|
|
||||||
|
declare readonly _serviceBrand: undefined;
|
||||||
|
|
||||||
|
readonly stateResource: URI = URI.from({ scheme: 'monaco', authority: 'stateResource' });
|
||||||
|
readonly userRoamingDataHome: URI = URI.from({ scheme: 'monaco', authority: 'userRoamingDataHome' });
|
||||||
|
readonly keyboardLayoutResource: URI = URI.from({ scheme: 'monaco', authority: 'keyboardLayoutResource' });
|
||||||
|
readonly argvResource: URI = URI.from({ scheme: 'monaco', authority: 'argvResource' });
|
||||||
|
readonly untitledWorkspacesHome: URI = URI.from({ scheme: 'monaco', authority: 'untitledWorkspacesHome' });
|
||||||
|
readonly workspaceStorageHome: URI = URI.from({ scheme: 'monaco', authority: 'workspaceStorageHome' });
|
||||||
|
readonly localHistoryHome: URI = URI.from({ scheme: 'monaco', authority: 'localHistoryHome' });
|
||||||
|
readonly cacheHome: URI = URI.from({ scheme: 'monaco', authority: 'cacheHome' });
|
||||||
|
readonly userDataSyncHome: URI = URI.from({ scheme: 'monaco', authority: 'userDataSyncHome' });
|
||||||
|
readonly sync: 'on' | 'off' | undefined = undefined;
|
||||||
|
readonly continueOn?: string | undefined = undefined;
|
||||||
|
readonly editSessionId?: string | undefined = undefined;
|
||||||
|
readonly debugExtensionHost: IExtensionHostDebugParams = { port: null, break: false };
|
||||||
|
readonly isExtensionDevelopment: boolean = false;
|
||||||
|
readonly disableExtensions: boolean | string[] = false;
|
||||||
|
readonly enableExtensions?: readonly string[] | undefined = undefined;
|
||||||
|
readonly extensionDevelopmentLocationURI?: URI[] | undefined = undefined;
|
||||||
|
readonly extensionDevelopmentKind?: ExtensionKind[] | undefined = undefined;
|
||||||
|
readonly extensionTestsLocationURI?: URI | undefined = undefined;
|
||||||
|
readonly logsHome: URI = URI.from({ scheme: 'monaco', authority: 'logsHome' });
|
||||||
|
readonly logLevel?: string | undefined = undefined;
|
||||||
|
readonly extensionLogLevel?: [string, string][] | undefined = undefined;
|
||||||
|
readonly verbose: boolean = false;
|
||||||
|
readonly isBuilt: boolean = false;
|
||||||
|
readonly disableTelemetry: boolean = false;
|
||||||
|
readonly serviceMachineIdResource: URI = URI.from({ scheme: 'monaco', authority: 'serviceMachineIdResource' });
|
||||||
|
readonly policyFile?: URI | undefined = undefined;
|
||||||
|
}
|
||||||
|
|
||||||
class StandaloneDialogService implements IDialogService {
|
class StandaloneDialogService implements IDialogService {
|
||||||
|
|
||||||
_serviceBrand: undefined;
|
_serviceBrand: undefined;
|
||||||
|
@ -1029,6 +1063,7 @@ registerSingleton(IWorkspaceContextService, StandaloneWorkspaceContextService, I
|
||||||
registerSingleton(ILabelService, StandaloneUriLabelService, InstantiationType.Eager);
|
registerSingleton(ILabelService, StandaloneUriLabelService, InstantiationType.Eager);
|
||||||
registerSingleton(ITelemetryService, StandaloneTelemetryService, InstantiationType.Eager);
|
registerSingleton(ITelemetryService, StandaloneTelemetryService, InstantiationType.Eager);
|
||||||
registerSingleton(IDialogService, StandaloneDialogService, InstantiationType.Eager);
|
registerSingleton(IDialogService, StandaloneDialogService, InstantiationType.Eager);
|
||||||
|
registerSingleton(IEnvironmentService, StandaloneEnvironmentService, InstantiationType.Eager);
|
||||||
registerSingleton(INotificationService, StandaloneNotificationService, InstantiationType.Eager);
|
registerSingleton(INotificationService, StandaloneNotificationService, InstantiationType.Eager);
|
||||||
registerSingleton(IMarkerService, MarkerService, InstantiationType.Eager);
|
registerSingleton(IMarkerService, MarkerService, InstantiationType.Eager);
|
||||||
registerSingleton(ILanguageService, StandaloneLanguageService, InstantiationType.Eager);
|
registerSingleton(ILanguageService, StandaloneLanguageService, InstantiationType.Eager);
|
||||||
|
|
Loading…
Reference in a new issue