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

Unified Diff: cc/trees/layer_tree_host.cc

Issue 961023002: (Reland) Always create top controls manager (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Removed calculate_top_controls_position flag from Android flags Created 5 years, 10 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: cc/trees/layer_tree_host.cc
diff --git a/cc/trees/layer_tree_host.cc b/cc/trees/layer_tree_host.cc
index 92e9c2593fc2a2c8a23eb897d85f37a08b143c33..d893b33c3374787a4dd4c8ff18e61bf0dce27e8c 100644
--- a/cc/trees/layer_tree_host.cc
+++ b/cc/trees/layer_tree_host.cc
@@ -448,11 +448,8 @@ scoped_ptr<LayerTreeHostImpl> LayerTreeHost::CreateLayerTreeHostImpl(
host_impl->SetUseGpuRasterization(UseGpuRasterization());
shared_bitmap_manager_ = NULL;
gpu_memory_buffer_manager_ = NULL;
- if (settings_.calculate_top_controls_position &&
- host_impl->top_controls_manager()) {
- top_controls_manager_weak_ptr_ =
- host_impl->top_controls_manager()->AsWeakPtr();
- }
+ top_controls_manager_weak_ptr_ =
+ host_impl->top_controls_manager()->AsWeakPtr();
input_handler_weak_ptr_ = host_impl->AsWeakPtr();
return host_impl.Pass();
}
@@ -1158,9 +1155,6 @@ void LayerTreeHost::SetDeviceScaleFactor(float device_scale_factor) {
void LayerTreeHost::UpdateTopControlsState(TopControlsState constraints,
TopControlsState current,
bool animate) {
- if (!settings_.calculate_top_controls_position)
- return;
-
// Top controls are only used in threaded mode.
proxy_->ImplThreadTaskRunner()->PostTask(
FROM_HERE,

Powered by Google App Engine
This is Rietveld 408576698