diff --git a/src/vs/workbench/api/browser/extHost.api.impl.ts b/src/vs/workbench/api/browser/extHost.api.impl.ts index 9cb20f377a9..6f2b5b04ea3 100644 --- a/src/vs/workbench/api/browser/extHost.api.impl.ts +++ b/src/vs/workbench/api/browser/extHost.api.impl.ts @@ -14,7 +14,7 @@ import {ExtHostConfiguration} from 'vs/workbench/api/common/extHostConfiguration import {ExtHostDiagnostics} from 'vs/workbench/api/common/extHostDiagnostics'; import {ExtHostWorkspace} from 'vs/workbench/api/common/extHostWorkspace'; import {ExtHostQuickOpen} from 'vs/workbench/api/browser/extHostQuickOpen'; -import {ExtHostStatusBar} from 'vs/workbench/api/browser/extHostStatusBar'; +import {ExtHostStatusBar} from 'vs/workbench/api/common/extHostStatusBar'; import {ExtHostCommands} from 'vs/workbench/api/common/extHostCommands'; import {ExtHostOutputService} from 'vs/workbench/api/common/extHostOutputService'; import {ExtHostMessageService} from 'vs/workbench/api/common/extHostMessageService'; diff --git a/src/vs/workbench/api/common/extHostDocuments.ts b/src/vs/workbench/api/common/extHostDocuments.ts index ec6596e89a5..36d57199be3 100644 --- a/src/vs/workbench/api/common/extHostDocuments.ts +++ b/src/vs/workbench/api/common/extHostDocuments.ts @@ -23,7 +23,6 @@ import * as vscode from 'vscode'; import {WordHelper} from 'vs/editor/common/model/textModelWithTokensHelpers'; import {IFileService} from 'vs/platform/files/common/files'; import {IUntitledEditorService} from 'vs/workbench/services/untitled/browser/untitledEditorService'; -import {UntitledEditorModel} from 'vs/workbench/browser/parts/editor/untitledEditorModel'; export interface IModelAddedData { url: URI; diff --git a/src/vs/workbench/api/browser/extHostStatusBar.ts b/src/vs/workbench/api/common/extHostStatusBar.ts similarity index 92% rename from src/vs/workbench/api/browser/extHostStatusBar.ts rename to src/vs/workbench/api/common/extHostStatusBar.ts index a32f84f0fac..f5b5e473efa 100644 --- a/src/vs/workbench/api/browser/extHostStatusBar.ts +++ b/src/vs/workbench/api/common/extHostStatusBar.ts @@ -4,12 +4,10 @@ *--------------------------------------------------------------------------------------------*/ 'use strict'; -import {TPromise} from 'vs/base/common/winjs.base'; import {Remotable, IThreadService} from 'vs/platform/thread/common/thread'; -import {IStatusbarService} from 'vs/workbench/services/statusbar/statusbarService'; -import {IDisposable, disposeAll} from 'vs/base/common/lifecycle'; -import {StatusbarAlignment as MainThreadStatusBarAlignment} from 'vs/workbench/browser/parts/statusbar/statusbar'; -import {StatusBarAlignment as ExtHostStatusBarAlignment, Disposable} from '../common/extHostTypes'; +import {IStatusbarService, StatusbarAlignment as MainThreadStatusBarAlignment} from 'vs/workbench/services/statusbar/common/statusbarService'; +import {IDisposable} from 'vs/base/common/lifecycle'; +import {StatusBarAlignment as ExtHostStatusBarAlignment, Disposable} from './extHostTypes'; import {StatusBarItem, StatusBarAlignment} from 'vscode'; export class ExtHostStatusBarEntry implements StatusBarItem { @@ -123,7 +121,7 @@ export class ExtHostStatusBarEntry implements StatusBarItem { class StatusBarMessage { private _item: StatusBarItem; - private _messages: {message:string}[] = []; + private _messages: { message: string }[] = []; constructor(statusBar: ExtHostStatusBar) { this._item = statusBar.createStatusBarEntry(ExtHostStatusBarAlignment.Left, Number.MIN_VALUE); @@ -192,7 +190,7 @@ export class ExtHostStatusBar { @Remotable.MainContext('MainThreadStatusBar') export class MainThreadStatusBar { - private mapIdToDisposable: { [id:number]: IDisposable }; + private mapIdToDisposable: { [id: number]: IDisposable }; constructor( @IStatusbarService private statusbarService: IStatusbarService diff --git a/src/vs/workbench/browser/parts/statusbar/statusbar.ts b/src/vs/workbench/browser/parts/statusbar/statusbar.ts index 450e771a40a..34958b43110 100644 --- a/src/vs/workbench/browser/parts/statusbar/statusbar.ts +++ b/src/vs/workbench/browser/parts/statusbar/statusbar.ts @@ -6,6 +6,7 @@ import {Registry} from 'vs/platform/platform'; import {IDisposable} from 'vs/base/common/lifecycle'; +import statusbarService = require('vs/workbench/services/statusbar/common/statusbarService'); import {SyncDescriptor0, createSyncDescriptor} from 'vs/platform/instantiation/common/descriptors'; import {INewConstructorSignature0} from 'vs/platform/instantiation/common/instantiation'; @@ -13,9 +14,7 @@ export interface IStatusbarItem { render(element: HTMLElement): IDisposable; } -export enum StatusbarAlignment { - LEFT, RIGHT -} +export import StatusbarAlignment = statusbarService.StatusbarAlignment; export class StatusbarItemDescriptor { diff --git a/src/vs/workbench/browser/parts/statusbar/statusbarPart.ts b/src/vs/workbench/browser/parts/statusbar/statusbarPart.ts index bd555ff144d..0440910cf65 100644 --- a/src/vs/workbench/browser/parts/statusbar/statusbarPart.ts +++ b/src/vs/workbench/browser/parts/statusbar/statusbarPart.ts @@ -23,7 +23,7 @@ import {StatusbarAlignment, IStatusbarRegistry, Extensions, IStatusbarItem} from import {IInstantiationService} from 'vs/platform/instantiation/common/instantiation'; import {ITelemetryService} from 'vs/platform/telemetry/common/telemetry'; import {IMessageService, Severity} from 'vs/platform/message/common/message'; -import {IStatusbarService, IStatusbarEntry} from 'vs/workbench/services/statusbar/statusbarService'; +import {IStatusbarService, IStatusbarEntry} from 'vs/workbench/services/statusbar/common/statusbarService'; export class StatusbarPart extends Part implements IStatusbarService { diff --git a/src/vs/workbench/browser/workbench.ts b/src/vs/workbench/browser/workbench.ts index 93708fb4b60..1fc2f8d3391 100644 --- a/src/vs/workbench/browser/workbench.ts +++ b/src/vs/workbench/browser/workbench.ts @@ -59,7 +59,7 @@ import {ITelemetryService} from 'vs/platform/telemetry/common/telemetry'; import {IThreadService} from 'vs/platform/thread/common/thread'; import {IPluginService} from 'vs/platform/plugins/common/plugins'; import {AbstractThreadService} from 'vs/platform/thread/common/abstractThreadService'; -import {IStatusbarService} from 'vs/workbench/services/statusbar/statusbarService'; +import {IStatusbarService} from 'vs/workbench/services/statusbar/common/statusbarService'; interface WorkbenchParams { workspace?: IWorkspace; diff --git a/src/vs/workbench/electron-browser/shell.ts b/src/vs/workbench/electron-browser/shell.ts index fcc1fd38e8d..5785827633f 100644 --- a/src/vs/workbench/electron-browser/shell.ts +++ b/src/vs/workbench/electron-browser/shell.ts @@ -58,7 +58,7 @@ import {JSONValidationExtensionPoint} from 'vs/platform/jsonschemas/common/jsonV import {LanguageConfigurationFileHandler} from 'vs/editor/node/languageConfiguration'; import {MainThreadFileSystemEventService} from 'vs/workbench/api/common/extHostFileSystemEventService'; import {MainThreadQuickOpen} from 'vs/workbench/api/browser/extHostQuickOpen'; -import {MainThreadStatusBar} from 'vs/workbench/api/browser/extHostStatusBar'; +import {MainThreadStatusBar} from 'vs/workbench/api/common/extHostStatusBar'; import {MainThreadCommands} from 'vs/workbench/api/common/extHostCommands'; import {RemoteTelemetryServiceHelper} from 'vs/platform/telemetry/common/abstractRemoteTelemetryService'; import {MainThreadDiagnostics} from 'vs/workbench/api/common/extHostDiagnostics'; diff --git a/src/vs/workbench/services/message/browser/messageService.ts b/src/vs/workbench/services/message/browser/messageService.ts index f33e510a844..4713711bd44 100644 --- a/src/vs/workbench/services/message/browser/messageService.ts +++ b/src/vs/workbench/services/message/browser/messageService.ts @@ -14,7 +14,7 @@ import {IMessageService, IMessageWithAction, IConfirmation, Severity} from 'vs/p import {ITelemetryService} from 'vs/platform/telemetry/common/telemetry'; import {IKeybindingService, IKeybindingContextKey} from 'vs/platform/keybinding/common/keybindingService'; import {IQuickOpenService} from 'vs/workbench/services/quickopen/browser/quickOpenService'; -import {IStatusbarService} from 'vs/workbench/services/statusbar/statusbarService'; +import {IStatusbarService} from 'vs/workbench/services/statusbar/common/statusbarService'; interface IBufferedMessage { severity: Severity; diff --git a/src/vs/workbench/services/statusbar/statusbarService.ts b/src/vs/workbench/services/statusbar/common/statusbarService.ts similarity index 94% rename from src/vs/workbench/services/statusbar/statusbarService.ts rename to src/vs/workbench/services/statusbar/common/statusbarService.ts index c011b131821..3d95c60eef2 100644 --- a/src/vs/workbench/services/statusbar/statusbarService.ts +++ b/src/vs/workbench/services/statusbar/common/statusbarService.ts @@ -6,11 +6,14 @@ 'use strict'; import {createDecorator, ServiceIdentifier} from 'vs/platform/instantiation/common/instantiation'; -import {StatusbarAlignment} from 'vs/workbench/browser/parts/statusbar/statusbar'; import {IDisposable} from 'vs/base/common/lifecycle'; export var IStatusbarService = createDecorator('statusbarService'); +export enum StatusbarAlignment { + LEFT, RIGHT +} + /** * A declarative way of describing a status bar entry */