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

Unified Diff: cc/input/scrollbar_animation_controller_unittest.cc

Issue 2762123004: cc: LayerTreeHostImpl uses element id to tick animations (Closed)
Patch Set: remove accidental debug print Created 3 years, 9 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/input/scrollbar_animation_controller_unittest.cc
diff --git a/cc/input/scrollbar_animation_controller_unittest.cc b/cc/input/scrollbar_animation_controller_unittest.cc
index 3d0855e65e1adeedc1842b264b4b39454ce6c77e..148c810ddd24068c9a0ed852f7ec4cba3c51adc2 100644
--- a/cc/input/scrollbar_animation_controller_unittest.cc
+++ b/cc/input/scrollbar_animation_controller_unittest.cc
@@ -1143,11 +1143,7 @@ class VerticalScrollbarAnimationControllerAndroidTest
};
TEST_F(ScrollbarAnimationControllerAndroidTest, DelayAnimationOnResize) {
- scrollbar_layer_->layer_tree_impl()
- ->property_trees()
- ->effect_tree.OnOpacityAnimated(0.0f,
- scrollbar_layer_->effect_tree_index(),
- scrollbar_layer_->layer_tree_impl());
+ scrollbar_layer_->SetOverlayScrollbarLayerOpacityAnimated(0.f);
scrollbar_controller_->DidScrollBegin();
scrollbar_controller_->DidScrollUpdate(true);
scrollbar_controller_->DidScrollEnd();
@@ -1155,11 +1151,7 @@ TEST_F(ScrollbarAnimationControllerAndroidTest, DelayAnimationOnResize) {
EXPECT_FLOAT_EQ(1.0f, scrollbar_layer_->Opacity());
EXPECT_EQ(delay_, base::TimeDelta::FromSeconds(2));
- scrollbar_layer_->layer_tree_impl()
- ->property_trees()
- ->effect_tree.OnOpacityAnimated(0.0f,
- scrollbar_layer_->effect_tree_index(),
- scrollbar_layer_->layer_tree_impl());
+ scrollbar_layer_->SetOverlayScrollbarLayerOpacityAnimated(0.f);
scrollbar_controller_->DidScrollUpdate(true);
// Delay animation on resize to 5 seconds.
EXPECT_FLOAT_EQ(1.0f, scrollbar_layer_->Opacity());
@@ -1167,22 +1159,14 @@ TEST_F(ScrollbarAnimationControllerAndroidTest, DelayAnimationOnResize) {
}
TEST_F(ScrollbarAnimationControllerAndroidTest, HiddenInBegin) {
- scrollbar_layer_->layer_tree_impl()
- ->property_trees()
- ->effect_tree.OnOpacityAnimated(0.0f,
- scrollbar_layer_->effect_tree_index(),
- scrollbar_layer_->layer_tree_impl());
+ scrollbar_layer_->SetOverlayScrollbarLayerOpacityAnimated(0.f);
scrollbar_controller_->Animate(base::TimeTicks());
EXPECT_FLOAT_EQ(0.0f, scrollbar_layer_->Opacity());
}
TEST_F(ScrollbarAnimationControllerAndroidTest,
HiddenAfterNonScrollingGesture) {
- scrollbar_layer_->layer_tree_impl()
- ->property_trees()
- ->effect_tree.OnOpacityAnimated(0.0f,
- scrollbar_layer_->effect_tree_index(),
- scrollbar_layer_->layer_tree_impl());
+ scrollbar_layer_->SetOverlayScrollbarLayerOpacityAnimated(0.f);
scrollbar_controller_->DidScrollBegin();
base::TimeTicks time;

Powered by Google App Engine
This is Rietveld 408576698