From f05ce105e85c6a4a9be9c667ef1cda150b270402 Mon Sep 17 00:00:00 2001 From: Asher Date: Tue, 26 Feb 2019 14:41:34 -0600 Subject: [PATCH] Update dialog to use workbench instead of client --- packages/vscode/src/dialog.ts | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/packages/vscode/src/dialog.ts b/packages/vscode/src/dialog.ts index f368920b..4f2e7bfb 100644 --- a/packages/vscode/src/dialog.ts +++ b/packages/vscode/src/dialog.ts @@ -1,8 +1,7 @@ -import { Emitter, Event } from "@coder/events"; -import { client as ideClient } from "@coder/ide/src/fill/client"; -import { client } from "@coder/vscode/src/client"; import * as fs from "fs"; import * as path from "path"; +import { Emitter, Event } from "@coder/events"; +import { client as ideClient } from "@coder/ide/src/fill/client"; import { $, addClass, append } from "vs/base/browser/dom"; import { HighlightedLabel } from "vs/base/browser/ui/highlightedlabel/highlightedLabel"; import { ObjectTree } from "vs/base/browser/ui/tree/objectTree"; @@ -13,8 +12,9 @@ import { getIconClasses } from "vs/editor/common/services/getIconClasses"; import { IModelService } from "vs/editor/common/services/modelService"; import { IModeService } from "vs/editor/common/services/modeService"; import { FileKind } from "vs/platform/files/common/files"; -import "./dialog.scss"; import { IThemeService } from "vs/platform/theme/common/themeService"; +import { workbench } from "./workbench"; +import "./dialog.scss"; declare var __non_webpack_require__: typeof require; @@ -115,7 +115,7 @@ class Dialog { const setProperty = (vari: string, id: string): void => { const getColor = (id: string): string | undefined => { - const ts = client.serviceCollection.get(IThemeService) as IThemeService; + const ts = workbench.serviceCollection.get(IThemeService) as IThemeService; const c = ts.getTheme().getColor(id); if (!c) { return; @@ -444,8 +444,8 @@ class DialogEntryRenderer implements ITreeRenderer, index: number, templateData: DialogEntryData): void { templateData.icon.className = "dialog-entry-icon monaco-icon-label"; const classes = getIconClasses( - client.serviceCollection.get(IModelService) as IModelService, - client.serviceCollection.get(IModeService) as IModeService, + workbench.serviceCollection.get(IModelService) as IModelService, + workbench.serviceCollection.get(IModeService) as IModeService, URI.file(node.element.name), node.element.isDirectory ? FileKind.FOLDER : FileKind.FILE, );