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

Unified Diff: cc/trees/layer_tree_host_impl_unittest.cc

Issue 2422353002: Iframe/div MD scrollbars get idle when mouse leaves the nested elements. (Closed)
Patch Set: Move the scrollbar animation logic to animation controllers. Created 4 years, 2 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
« cc/trees/layer_tree_host_impl.cc ('K') | « 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 de7eb4f281d773882b321171860e5d9cf4446209..b9758420d3ce5e177e82e5de8beecfd7bd65084c 100644
--- a/cc/trees/layer_tree_host_impl_unittest.cc
+++ b/cc/trees/layer_tree_host_impl_unittest.cc
@@ -3230,15 +3230,13 @@ void LayerTreeHostImplTest::SetupMouseMoveAtWithDeviceScale(
EXPECT_TRUE(scrollbar_animation_controller->mouse_is_near_scrollbar());
did_request_redraw_ = false;
- EXPECT_EQ(Layer::INVALID_ID,
- host_impl_->scroll_layer_id_when_mouse_over_scrollbar());
+ EXPECT_FALSE(scrollbar_animation_controller->mouse_is_over_scrollbar());
host_impl_->MouseMoveAt(gfx::Point(10, 100));
- EXPECT_EQ(117, host_impl_->scroll_layer_id_when_mouse_over_scrollbar());
+ EXPECT_TRUE(scrollbar_animation_controller->mouse_is_over_scrollbar());
host_impl_->MouseMoveAt(gfx::Point(10, 120));
- EXPECT_EQ(117, host_impl_->scroll_layer_id_when_mouse_over_scrollbar());
+ EXPECT_TRUE(scrollbar_animation_controller->mouse_is_over_scrollbar());
host_impl_->MouseMoveAt(gfx::Point(150, 120));
- EXPECT_EQ(Layer::INVALID_ID,
- host_impl_->scroll_layer_id_when_mouse_over_scrollbar());
+ EXPECT_FALSE(scrollbar_animation_controller->mouse_is_over_scrollbar());
}
TEST_F(LayerTreeHostImplTest, MouseMoveAtWithDeviceScaleOf1) {
« cc/trees/layer_tree_host_impl.cc ('K') | « 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