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

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

Issue 2490383002: Revert of Resolves layering violation in SynchronousCompositorHost creation (Closed)
Patch Set: Created 4 years, 1 month 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_widget_host_view_android.cc
diff --git a/content/browser/renderer_host/render_widget_host_view_android.cc b/content/browser/renderer_host/render_widget_host_view_android.cc
index 54d8a0685b4d83c9f1dd960c4294d1c757469e07..78c0d2271379a3629f84f3621665b921121d1daf 100644
--- a/content/browser/renderer_host/render_widget_host_view_android.cc
+++ b/content/browser/renderer_host/render_widget_host_view_android.cc
@@ -450,7 +450,6 @@
this),
stylus_text_selector_(this),
using_browser_compositor_(CompositorImpl::IsInitialized()),
- synchronous_compositor_client_(nullptr),
frame_evictor_(new DelegatedFrameEvictor(this)),
locks_on_frame_count_(0),
observing_root_window_(false),
@@ -1203,14 +1202,6 @@
&RenderFrameDevToolsAgentHost::SynchronousSwapCompositorFrame,
static_cast<RenderFrameDevToolsAgentHost*>(dtah.get()),
base::Passed(&frame_metadata)));
- }
-}
-
-void RenderWidgetHostViewAndroid::SetSynchronousCompositorClient(
- SynchronousCompositorClient* client) {
- synchronous_compositor_client_ = client;
- if (!sync_compositor_ && synchronous_compositor_client_) {
- sync_compositor_ = SynchronousCompositorHost::Create(this);
}
}
@@ -1797,6 +1788,11 @@
overscroll_controller_ = CreateOverscrollController(
content_view_core_, ui::GetScaleFactorForNativeView(GetNativeView()));
}
+
+ if (!sync_compositor_) {
+ sync_compositor_ = SynchronousCompositorHost::Create(
+ this, content_view_core_->GetWebContents());
+ }
}
void RenderWidgetHostViewAndroid::RunAckCallbacks() {
« no previous file with comments | « content/browser/renderer_host/render_widget_host_view_android.h ('k') | content/browser/web_contents/web_contents_android.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698