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

Unified Diff: cc/animation/scrollbar_animation_controller_thinning_unittest.cc

Issue 960873002: Update from https://crrev.com/318214 (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: 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
« no previous file with comments | « cc/animation/scrollbar_animation_controller_thinning.cc ('k') | cc/base/switches.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 04036ba639550987fb8aee6811c8bf240a661d24..01763c91cae55f194eeaf02b8b3761fa1a2b026e 100644
--- a/cc/animation/scrollbar_animation_controller_thinning_unittest.cc
+++ b/cc/animation/scrollbar_animation_controller_thinning_unittest.cc
@@ -22,11 +22,22 @@ class ScrollbarAnimationControllerThinningTest
ScrollbarAnimationControllerThinningTest()
: host_impl_(&proxy_, &shared_bitmap_manager_) {}
- void PostDelayedScrollbarFade(const base::Closure& start_fade,
- base::TimeDelta delay) override {
+ void StartAnimatingScrollbarAnimationController(
+ ScrollbarAnimationController* controller) override {
+ is_animating_ = true;
+ }
+ void StopAnimatingScrollbarAnimationController(
+ ScrollbarAnimationController* controller) override {
+ is_animating_ = false;
+ }
+ void PostDelayedScrollbarAnimationTask(const base::Closure& start_fade,
+ base::TimeDelta delay) override {
start_fade_ = start_fade;
+ delay_ = delay;
+ }
+ void SetNeedsRedrawForScrollbarAnimation() override {
+ did_request_redraw_ = true;
}
- void SetNeedsScrollbarAnimationFrame() override {}
protected:
void SetUp() override {
@@ -57,11 +68,8 @@ class ScrollbarAnimationControllerThinningTest
scroll_layer_ptr->SetBounds(gfx::Size(200, 200));
scrollbar_controller_ = ScrollbarAnimationControllerThinning::Create(
- scroll_layer_ptr,
- this,
- base::TimeDelta::FromSeconds(2),
- base::TimeDelta::FromSeconds(5),
- base::TimeDelta::FromSeconds(3));
+ scroll_layer_ptr, this, base::TimeDelta::FromSeconds(2),
+ base::TimeDelta::FromSeconds(5), base::TimeDelta::FromSeconds(3));
}
FakeImplProxy proxy_;
@@ -72,6 +80,9 @@ class ScrollbarAnimationControllerThinningTest
scoped_ptr<SolidColorScrollbarLayerImpl> scrollbar_layer_;
base::Closure start_fade_;
+ base::TimeDelta delay_;
+ bool is_animating_;
+ bool did_request_redraw_;
};
// Check initialization of scrollbar.
« no previous file with comments | « cc/animation/scrollbar_animation_controller_thinning.cc ('k') | cc/base/switches.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698