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

Unified Diff: cc/animation/scrollbar_animation_controller_thinning_unittest.cc

Issue 608223002: [Android]Increase Scrollbar fade delay on Resize. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added test case Created 6 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
Index: cc/animation/scrollbar_animation_controller_thinning_unittest.cc
diff --git a/cc/animation/scrollbar_animation_controller_thinning_unittest.cc b/cc/animation/scrollbar_animation_controller_thinning_unittest.cc
index 6dad5b06a2fcb3f686371f4af016b5858343810f..beef123f2b746d171a56546d39695a063538b2f3 100644
--- a/cc/animation/scrollbar_animation_controller_thinning_unittest.cc
+++ b/cc/animation/scrollbar_animation_controller_thinning_unittest.cc
@@ -58,6 +58,7 @@ class ScrollbarAnimationControllerThinningTest
scroll_layer_ptr,
this,
base::TimeDelta::FromSeconds(2),
+ base::TimeDelta::FromSeconds(5),
base::TimeDelta::FromSeconds(3));
}
@@ -83,7 +84,7 @@ TEST_F(ScrollbarAnimationControllerThinningTest, Idle) {
TEST_F(ScrollbarAnimationControllerThinningTest, AwakenByProgrammaticScroll) {
base::TimeTicks time;
time += base::TimeDelta::FromSeconds(1);
- scrollbar_controller_->DidScrollUpdate();
+ scrollbar_controller_->DidScrollUpdate(false);
EXPECT_FLOAT_EQ(1.0f, scrollbar_layer_->opacity());
// Scrollbar doesn't change size if triggered by scroll.
EXPECT_FLOAT_EQ(0.4f, scrollbar_layer_->thumb_thickness_scale_factor());
@@ -96,7 +97,7 @@ TEST_F(ScrollbarAnimationControllerThinningTest, AwakenByProgrammaticScroll) {
EXPECT_FLOAT_EQ(0.4f, scrollbar_layer_->thumb_thickness_scale_factor());
// Subsequent scroll restarts animation.
- scrollbar_controller_->DidScrollUpdate();
+ scrollbar_controller_->DidScrollUpdate(false);
start_fade_.Run();
@@ -134,7 +135,7 @@ TEST_F(ScrollbarAnimationControllerThinningTest, ScrollWithMouseNear) {
scrollbar_controller_->Animate(time);
EXPECT_FLOAT_EQ(1.0f, scrollbar_layer_->thumb_thickness_scale_factor());
- scrollbar_controller_->DidScrollUpdate();
+ scrollbar_controller_->DidScrollUpdate(false);
start_fade_.Run();
scrollbar_controller_->Animate(time);
EXPECT_FLOAT_EQ(1.0f, scrollbar_layer_->opacity());

Powered by Google App Engine
This is Rietveld 408576698