Adding toWebviewResource api

For #76489
This commit is contained in:
Matt Bierner
2019-07-03 19:14:19 -07:00
parent 3492642650
commit a558a9504a
20 changed files with 168 additions and 114 deletions

View File

@@ -12,7 +12,6 @@ import { IWebviewService, Webview } from 'vs/workbench/contrib/webview/common/we
import { DisposableStore } from 'vs/base/common/lifecycle';
import { IActiveCodeEditor, IViewZone } from 'vs/editor/browser/editorBrowser';
import { ExtensionIdentifier } from 'vs/platform/extensions/common/extensions';
import { IEnvironmentService } from 'vs/platform/environment/common/environment';
// todo@joh move these things back into something like contrib/insets
class EditorWebviewZone implements IViewZone {
@@ -60,7 +59,6 @@ export class MainThreadEditorInsets implements MainThreadEditorInsetsShape {
constructor(
context: IExtHostContext,
@IEnvironmentService private readonly _environmentService: IEnvironmentService,
@ICodeEditorService private readonly _editorService: ICodeEditorService,
@IWebviewService private readonly _webviewService: IWebviewService,
) {
@@ -147,8 +145,4 @@ export class MainThreadEditorInsets implements MainThreadEditorInsetsShape {
}
return inset;
}
async $getResourceRoot(_handle: number): Promise<string> {
return this._environmentService.webviewResourceRoot;
}
}