move ipc use from rvh to rfh
This commit is contained in:
parent
0d12fc3033
commit
3cfe66e4c3
18 changed files with 222 additions and 197 deletions
|
@ -7,6 +7,8 @@
|
|||
#include "atom/common/api/api_messages.h"
|
||||
#include "base/strings/utf_string_conversions.h"
|
||||
#include "base/values.h"
|
||||
#include "content/public/browser/render_frame_host.h"
|
||||
#include "content/public/browser/web_contents.h"
|
||||
|
||||
namespace atom {
|
||||
|
||||
|
@ -35,7 +37,11 @@ void RemoteCallbackFreer::RunDestructor() {
|
|||
base::ASCIIToUTF16("ELECTRON_RENDERER_RELEASE_CALLBACK");
|
||||
base::ListValue args;
|
||||
args.AppendInteger(object_id_);
|
||||
Send(new AtomViewMsg_Message(routing_id(), false, channel, args));
|
||||
auto frame_host = web_contents()->GetMainFrame();
|
||||
if (frame_host) {
|
||||
frame_host->Send(new AtomFrameMsg_Message(frame_host->GetRoutingID(), false,
|
||||
channel, args));
|
||||
}
|
||||
|
||||
Observe(nullptr);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue