Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(515)

Side by Side Diff: content/browser/frame_host/render_frame_proxy_host.cc

Issue 2383853003: Move FrameMsg_NewFrame/NewFrameProxy to mojom (Closed)
Patch Set: Move FrameMsg_NewFrame/NewFrameProxy to mojom Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/frame_host/render_frame_proxy_host.h" 5 #include "content/browser/frame_host/render_frame_proxy_host.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/lazy_instance.h" 9 #include "base/lazy_instance.h"
10 #include "content/browser/bad_message.h" 10 #include "content/browser/bad_message.h"
(...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after
177 parent_routing_id = parent_proxy->GetRoutingID(); 177 parent_routing_id = parent_proxy->GetRoutingID();
178 CHECK_NE(parent_routing_id, MSG_ROUTING_NONE); 178 CHECK_NE(parent_routing_id, MSG_ROUTING_NONE);
179 } 179 }
180 180
181 int opener_routing_id = MSG_ROUTING_NONE; 181 int opener_routing_id = MSG_ROUTING_NONE;
182 if (frame_tree_node_->opener()) { 182 if (frame_tree_node_->opener()) {
183 opener_routing_id = frame_tree_node_->render_manager()->GetOpenerRoutingID( 183 opener_routing_id = frame_tree_node_->render_manager()->GetOpenerRoutingID(
184 site_instance_.get()); 184 site_instance_.get());
185 } 185 }
186 186
187 Send(new FrameMsg_NewFrameProxy(routing_id_, 187 int view_routing_id = frame_tree_node_->frame_tree()
188 frame_tree_node_->frame_tree() 188 ->GetRenderViewHost(site_instance_.get())->GetRoutingID();
189 ->GetRenderViewHost(site_instance_.get()) 189 RenderProcessHostImpl::GetRendererInterface(GetProcess())->CreateFrameProxy(
190 ->GetRoutingID(), 190 routing_id_, view_routing_id, opener_routing_id, parent_routing_id,
191 opener_routing_id, 191 frame_tree_node_->current_replication_state());
192 parent_routing_id,
193 frame_tree_node_
194 ->current_replication_state()));
195 192
196 render_frame_proxy_created_ = true; 193 render_frame_proxy_created_ = true;
197 194
198 // For subframes, initialize the proxy's FrameOwnerProperties only if they 195 // For subframes, initialize the proxy's FrameOwnerProperties only if they
199 // differ from default values. 196 // differ from default values.
200 bool should_send_properties = 197 bool should_send_properties =
201 frame_tree_node_->frame_owner_properties() != FrameOwnerProperties(); 198 frame_tree_node_->frame_owner_properties() != FrameOwnerProperties();
202 if (frame_tree_node_->parent() && should_send_properties) { 199 if (frame_tree_node_->parent() && should_send_properties) {
203 Send(new FrameMsg_SetFrameOwnerProperties( 200 Send(new FrameMsg_SetFrameOwnerProperties(
204 routing_id_, frame_tree_node_->frame_owner_properties())); 201 routing_id_, frame_tree_node_->frame_owner_properties()));
(...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after
369 target_rfh->Send(new FrameMsg_AdvanceFocus(target_rfh->GetRoutingID(), type, 366 target_rfh->Send(new FrameMsg_AdvanceFocus(target_rfh->GetRoutingID(), type,
370 source_proxy_routing_id)); 367 source_proxy_routing_id));
371 } 368 }
372 369
373 void RenderFrameProxyHost::OnFrameFocused() { 370 void RenderFrameProxyHost::OnFrameFocused() {
374 frame_tree_node_->current_frame_host()->delegate()->SetFocusedFrame( 371 frame_tree_node_->current_frame_host()->delegate()->SetFocusedFrame(
375 frame_tree_node_, GetSiteInstance()); 372 frame_tree_node_, GetSiteInstance());
376 } 373 }
377 374
378 } // namespace content 375 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/frame_host/render_frame_host_impl.cc ('k') | content/browser/renderer_host/render_process_host_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698