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

Unified Diff: content/browser/web_contents/web_contents_impl.cc

Issue 10827078: Support frame tree propagation between renderers in the same browsing instance. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixes based on more comments from Albert. Created 8 years, 4 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/web_contents/web_contents_impl.cc
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
index 61d98d8faab7f8eaa2baecf2311112c8b073bb36..4d0e484001f91c67f815e4d3ec7e614ea571be6a 100644
--- a/content/browser/web_contents/web_contents_impl.cc
+++ b/content/browser/web_contents/web_contents_impl.cc
@@ -2746,6 +2746,10 @@ void WebContentsImpl::DidChangeLoadProgress(double progress) {
delegate_->LoadProgressChanged(this, progress);
}
+void WebContentsImpl::DidUpdateFrameTree(RenderViewHost* rvh) {
+ render_manager_.DidUpdateFrameTree(rvh);
+}
+
void WebContentsImpl::DocumentAvailableInMainFrame(
RenderViewHost* render_view_host) {
FOR_EACH_OBSERVER(WebContentsObserver, observers_,
@@ -2839,6 +2843,15 @@ void WebContentsImpl::RouteMessageEvent(
return;
ViewMsg_PostMessage_Params new_params(params);
+ RenderViewHost* active_rvh = GetRenderViewHost();
+
+ if (active_rvh->GetProcess()->GetID() != params.target_process_id) {
+ LOG(ERROR) << "Possibly race condition trying to deliver to " <<
Charlie Reis 2012/08/22 22:08:34 nit: Possibly -> Possible Hmm, I'm a little conce
nasko 2012/08/23 21:55:53 Done.
+ params.target_process_id << ", which doesn't match " <<
+ active_rvh->GetProcess()->GetID();
+ return;
+ }
+ DCHECK(params.target_frame_id != 0);
// If there is a source_routing_id, translate it to the routing ID for
// the equivalent swapped out RVH in the target process. If we need

Powered by Google App Engine
This is Rietveld 408576698