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

Unified Diff: cc/animation/scrollbar_animation_controller_linear_fade.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
Index: cc/animation/scrollbar_animation_controller_linear_fade.cc
diff --git a/cc/animation/scrollbar_animation_controller_linear_fade.cc b/cc/animation/scrollbar_animation_controller_linear_fade.cc
index 1b5dfd933daf117cdacc272b4d9cdb11c26d2def..d1049bda1cb9d18d6bb6c26552db6ca79f6e55a2 100644
--- a/cc/animation/scrollbar_animation_controller_linear_fade.cc
+++ b/cc/animation/scrollbar_animation_controller_linear_fade.cc
@@ -17,12 +17,9 @@ ScrollbarAnimationControllerLinearFade::Create(
base::TimeDelta delay_before_starting,
base::TimeDelta resize_delay_before_starting,
base::TimeDelta duration) {
- return make_scoped_ptr(
- new ScrollbarAnimationControllerLinearFade(scroll_layer,
- client,
- delay_before_starting,
- resize_delay_before_starting,
- duration));
+ return make_scoped_ptr(new ScrollbarAnimationControllerLinearFade(
+ scroll_layer, client, delay_before_starting, resize_delay_before_starting,
+ duration));
}
ScrollbarAnimationControllerLinearFade::ScrollbarAnimationControllerLinearFade(
@@ -31,18 +28,20 @@ ScrollbarAnimationControllerLinearFade::ScrollbarAnimationControllerLinearFade(
base::TimeDelta delay_before_starting,
base::TimeDelta resize_delay_before_starting,
base::TimeDelta duration)
- : ScrollbarAnimationController(client,
+ : ScrollbarAnimationController(scroll_layer,
+ client,
delay_before_starting,
resize_delay_before_starting,
- duration),
- scroll_layer_(scroll_layer) {
+ duration) {
}
ScrollbarAnimationControllerLinearFade::
- ~ScrollbarAnimationControllerLinearFade() {}
+ ~ScrollbarAnimationControllerLinearFade() {
+}
void ScrollbarAnimationControllerLinearFade::RunAnimationFrame(float progress) {
ApplyOpacityToScrollbars(1.f - progress);
+ client_->SetNeedsRedrawForScrollbarAnimation();
if (progress == 1.f)
StopAnimation();
}
@@ -59,8 +58,7 @@ void ScrollbarAnimationControllerLinearFade::ApplyOpacityToScrollbars(
LayerImpl::ScrollbarSet* scrollbars = scroll_layer_->scrollbars();
for (LayerImpl::ScrollbarSet::iterator it = scrollbars->begin();
- it != scrollbars->end();
- ++it) {
+ it != scrollbars->end(); ++it) {
ScrollbarLayerImplBase* scrollbar = *it;
if (scrollbar->is_overlay_scrollbar())

Powered by Google App Engine
This is Rietveld 408576698