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

Unified Diff: content/browser/renderer_host/render_view_host_impl.cc

Issue 1199313006: Disable support for swapped out RenderFrame(Host) on desktop. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 6 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/renderer_host/render_view_host_impl.cc
diff --git a/content/browser/renderer_host/render_view_host_impl.cc b/content/browser/renderer_host/render_view_host_impl.cc
index e0eb5dc42c629c922eee850a98fe2945752f9611..568a213dc043b2cd2dfa04a00db6f4bf4a4b4088 100644
--- a/content/browser/renderer_host/render_view_host_impl.cc
+++ b/content/browser/renderer_host/render_view_host_impl.cc
@@ -224,6 +224,10 @@ RenderViewHostImpl::RenderViewHostImpl(
is_focused_element_editable_(false),
updating_web_preferences_(false),
weak_factory_(this) {
+ LOG(ERROR) << "RVH[" << this << "]::RVH:"
+ << " routing_id:" << routing_id
+ << " site:" << instance->GetId() << "," << instance->GetSiteURL();
+
DCHECK(instance_.get());
CHECK(delegate_); // http://crbug.com/82827
@@ -263,6 +267,7 @@ RenderViewHostImpl::~RenderViewHostImpl() {
delegate_->RenderViewDeleted(this);
GetProcess()->RemoveObserver(this);
+ LOG(ERROR) << "RVH[" << this << "]::~RVH";
}
RenderViewHostDelegate* RenderViewHostImpl::GetDelegate() const {
@@ -284,15 +289,23 @@ bool RenderViewHostImpl::CreateRenderView(
"RenderViewHostImpl::CreateRenderView");
DCHECK(!IsRenderViewLive()) << "Creating view twice";
+ LOG(ERROR) << "RVH[" << this << "]::CreateRenderView: ";
+
// The process may (if we're sharing a process with another host that already
// initialized it) or may not (we have our own process or the old process
// crashed) have been initialized. Calling Init multiple times will be
// ignored, so this is safe.
- if (!GetProcess()->Init())
+ if (!GetProcess()->Init()) {
+ LOG(ERROR) << "RVH[" << this << "]::CreateRenderView: "
+ << " failed to init process";
return false;
+ }
DCHECK(GetProcess()->HasConnection());
DCHECK(GetProcess()->GetBrowserContext());
+ LOG(ERROR) << "RVH[" << this << "]::CreateRenderView: "
+ << " setting initialized to true";
+
set_renderer_initialized(true);
GpuSurfaceTracker::Get()->SetSurfaceHandle(
@@ -331,8 +344,11 @@ bool RenderViewHostImpl::CreateRenderView(
params.max_size = max_size_for_auto_resize();
GetResizeParams(&params.initial_size);
- if (!Send(new ViewMsg_New(params)))
+ if (!Send(new ViewMsg_New(params))) {
+ LOG(ERROR) << "RVH[" << this << "]::CreateRenderView: "
+ << " failed to send ViewMsg_New";
return false;
+ }
SetInitialRenderSizeParams(params.initial_size);
// If the RWHV has not yet been set, the surface ID namespace will get
@@ -353,6 +369,9 @@ bool RenderViewHostImpl::CreateRenderView(
// Since this method can create the main RenderFrame in the renderer process,
// set the proper state on its corresponding RenderFrameHost.
if (main_frame_routing_id_ != MSG_ROUTING_NONE) {
+ LOG(ERROR) << "RVH[" << this << "]::CreateRenderView: "
+ << " main_frame_routing_id_:" << main_frame_routing_id_
+ << " setting RFH as created";
RenderFrameHostImpl::FromID(GetProcess()->GetID(), main_frame_routing_id_)
->SetRenderFrameCreated(true);
}

Powered by Google App Engine
This is Rietveld 408576698