From 1f97cee7c92cede93a6e7730d8a6510eaba0a62e Mon Sep 17 00:00:00 2001 From: Cheng Zhao Date: Tue, 23 Jun 2015 16:43:55 +0800 Subject: [PATCH] Fix release render view with wrong ID --- atom/browser/api/atom_api_web_contents.cc | 4 +--- atom/browser/api/lib/web-contents.coffee | 4 ++-- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/atom/browser/api/atom_api_web_contents.cc b/atom/browser/api/atom_api_web_contents.cc index e87219d3710e..85b0e3d8a85c 100644 --- a/atom/browser/api/atom_api_web_contents.cc +++ b/atom/browser/api/atom_api_web_contents.cc @@ -249,9 +249,7 @@ void WebContents::ExitFullscreenModeForTab(content::WebContents* source) { } void WebContents::RenderViewDeleted(content::RenderViewHost* render_view_host) { - Emit("render-view-deleted", - render_view_host->GetProcess()->GetID(), - render_view_host->GetRoutingID()); + Emit("render-view-deleted", render_view_host->GetProcess()->GetID()); } void WebContents::RenderProcessGone(base::TerminationStatus status) { diff --git a/atom/browser/api/lib/web-contents.coffee b/atom/browser/api/lib/web-contents.coffee index 64aaf2bd415c..b635ab2a5f26 100644 --- a/atom/browser/api/lib/web-contents.coffee +++ b/atom/browser/api/lib/web-contents.coffee @@ -32,8 +32,8 @@ wrapWebContents = (webContents) -> # Tell the rpc server that a render view has been deleted and we need to # release all objects owned by it. - webContents.on 'render-view-deleted', (event, processId, routingId) -> - process.emit 'ATOM_BROWSER_RELEASE_RENDER_VIEW', "#{processId}-#{routingId}" + webContents.on 'render-view-deleted', (event, processId) -> + process.emit 'ATOM_BROWSER_RELEASE_RENDER_VIEW', processId # Dispatch IPC messages to the ipc module. webContents.on 'ipc-message', (event, packed) ->