diff --git a/src/vs/workbench/api/electron-browser/mainThreadDecorations.ts b/src/vs/workbench/api/electron-browser/mainThreadDecorations.ts index c6b4191409359257c14a9ffcd236986c7dcf635e..ff5497aa5ebe04a9fa44747eee300ff8ccbc346d 100644 --- a/src/vs/workbench/api/electron-browser/mainThreadDecorations.ts +++ b/src/vs/workbench/api/electron-browser/mainThreadDecorations.ts @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ 'use strict'; -import URI from 'vs/base/common/uri'; +import URI, { UriComponents } from 'vs/base/common/uri'; import { Emitter } from 'vs/base/common/event'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { ExtHostContext, MainContext, IExtHostContext, MainThreadDecorationsShape, ExtHostDecorationsShape } from '../node/extHost.protocol'; @@ -54,9 +54,9 @@ export class MainThreadDecorations implements MainThreadDecorationsShape { this._provider.set(handle, [emitter, registration]); } - $onDidChange(handle: number, resources: URI[]): void { + $onDidChange(handle: number, resources: UriComponents[]): void { const [emitter] = this._provider.get(handle); - emitter.fire(resources); + emitter.fire(resources.map(URI.revive)); } $unregisterDecorationProvider(handle: number): void { diff --git a/src/vs/workbench/api/node/extHost.protocol.ts b/src/vs/workbench/api/node/extHost.protocol.ts index 7112db29fbf8ed6155b55c1b19dce588ef33cd55..a59e7c6338cc3e82b8f5871a67d6af26af786172 100644 --- a/src/vs/workbench/api/node/extHost.protocol.ts +++ b/src/vs/workbench/api/node/extHost.protocol.ts @@ -140,7 +140,7 @@ export interface MainThreadDiaglogsShape extends IDisposable { export interface MainThreadDecorationsShape extends IDisposable { $registerDecorationProvider(handle: number, label: string): void; $unregisterDecorationProvider(handle: number): void; - $onDidChange(handle: number, resources: URI[]): void; + $onDidChange(handle: number, resources: UriComponents[]): void; } export interface MainThreadDocumentContentProvidersShape extends IDisposable { @@ -668,7 +668,7 @@ export const MainContext = { MainThreadCommands: >createMainId('MainThreadCommands', ProxyType.CustomMarshaller), MainThreadConfiguration: createMainId('MainThreadConfiguration', ProxyType.CustomMarshaller), MainThreadDebugService: createMainId('MainThreadDebugService', ProxyType.CustomMarshaller), - MainThreadDecorations: createMainId('MainThreadDecorations', ProxyType.CustomMarshaller), + MainThreadDecorations: createMainId('MainThreadDecorations', ProxyType.NativeJSON), MainThreadDiagnostics: createMainId('MainThreadDiagnostics', ProxyType.CustomMarshaller), MainThreadDialogs: createMainId('MainThreadDiaglogs', ProxyType.CustomMarshaller), MainThreadDocuments: createMainId('MainThreadDocuments'),