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

Unified Diff: cc/trees/layer_tree_host_impl_unittest.cc

Issue 597393002: Make compositor initialize top controls to be shown. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed unit tests Created 6 years, 3 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
« no previous file with comments | « cc/trees/layer_tree_host_impl.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/trees/layer_tree_host_impl_unittest.cc
diff --git a/cc/trees/layer_tree_host_impl_unittest.cc b/cc/trees/layer_tree_host_impl_unittest.cc
index 92087fe361ddf662e5bc02633670f28f1c9c8c2e..8c43f04900a22a6d3ce1bb59464b9a6fb81fb98f 100644
--- a/cc/trees/layer_tree_host_impl_unittest.cc
+++ b/cc/trees/layer_tree_host_impl_unittest.cc
@@ -2178,8 +2178,6 @@ class LayerTreeHostImplTopControlsTest : public LayerTreeHostImplTest {
// Set a viewport size that is large enough to contain both the top controls
// and some content.
host_impl_->SetViewportSize(viewport_size_);
- host_impl_->active_tree()->set_top_controls_content_offset(
- settings_.top_controls_height);
host_impl_->SetTopControlsLayoutHeight(
settings_.top_controls_height);
LayerImpl* root_clip_ptr = host_impl_->active_tree()->root_layer();
@@ -2280,6 +2278,7 @@ TEST_F(LayerTreeHostImplTopControlsTest, PositionTopControlsExplicitly) {
SetupTopControlsAndScrollLayer();
DrawFrame();
+ host_impl_->active_tree()->set_top_controls_delta(0.f);
host_impl_->active_tree()->set_top_controls_content_offset(30.f);
EXPECT_EQ(30.f, host_impl_->top_controls_manager()->ContentTopOffset());
EXPECT_EQ(-20.f, host_impl_->top_controls_manager()->ControlsTopOffset());
« no previous file with comments | « cc/trees/layer_tree_host_impl.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698