From cdd9a731f9ea3c119621463c2d26f2725079172f Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Tue, 17 Apr 2018 16:22:44 -0700 Subject: [PATCH] Use standard 'postMessage' name --- src/vs/workbench/api/electron-browser/mainThreadWebview.ts | 2 +- src/vs/workbench/api/node/extHost.protocol.ts | 2 +- src/vs/workbench/api/node/extHostWebview.ts | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/vs/workbench/api/electron-browser/mainThreadWebview.ts b/src/vs/workbench/api/electron-browser/mainThreadWebview.ts index b3bff528318ad..4f007ab24395e 100644 --- a/src/vs/workbench/api/electron-browser/mainThreadWebview.ts +++ b/src/vs/workbench/api/electron-browser/mainThreadWebview.ts @@ -101,7 +101,7 @@ export class MainThreadWebviews implements MainThreadWebviewsShape, WebviewReviv this._webviewService.revealWebview(webview, column); } - async $sendMessage(handle: WebviewPanelHandle, message: any): TPromise { + async $postMessage(handle: WebviewPanelHandle, message: any): TPromise { const webview = this.getWebview(handle); const editors = this._editorService.getVisibleEditors() .filter(e => e instanceof WebviewEditor) diff --git a/src/vs/workbench/api/node/extHost.protocol.ts b/src/vs/workbench/api/node/extHost.protocol.ts index 3f5c9595b4903..37f274df23afe 100644 --- a/src/vs/workbench/api/node/extHost.protocol.ts +++ b/src/vs/workbench/api/node/extHost.protocol.ts @@ -355,7 +355,7 @@ export interface MainThreadWebviewsShape extends IDisposable { $reveal(handle: WebviewPanelHandle, column: EditorPosition): void; $setTitle(handle: WebviewPanelHandle, value: string): void; $setHtml(handle: WebviewPanelHandle, value: string): void; - $sendMessage(handle: WebviewPanelHandle, value: any): Thenable; + $postMessage(handle: WebviewPanelHandle, value: any): Thenable; $registerSerializer(viewType: string): void; $unregisterSerializer(viewType: string): void; diff --git a/src/vs/workbench/api/node/extHostWebview.ts b/src/vs/workbench/api/node/extHostWebview.ts index d82e1235db2ae..53eb8d3197250 100644 --- a/src/vs/workbench/api/node/extHostWebview.ts +++ b/src/vs/workbench/api/node/extHostWebview.ts @@ -74,7 +74,7 @@ export class ExtHostWebview implements vscode.Webview { public postMessage(message: any): Thenable { this.assertNotDisposed(); - return this._proxy.$sendMessage(this._handle, message); + return this._proxy.$postMessage(this._handle, message); } public reveal(viewColumn: vscode.ViewColumn): void { @@ -173,7 +173,7 @@ export class ExtHostWebviewPanel implements vscode.WebviewPanel { public postMessage(message: any): Thenable { this.assertNotDisposed(); - return this._proxy.$sendMessage(this._handle, message); + return this._proxy.$postMessage(this._handle, message); } public reveal(viewColumn: vscode.ViewColumn): void {