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

Unified Diff: cc/animation/scroll_offset_animations_impl.cc

Issue 2840883003: Experimental fix for scroll animation update bug. [DO NOT COMMIT THIS CHANGE]
Patch Set: Created 3 years, 8 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 | « no previous file | cc/trees/layer_tree_host_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/animation/scroll_offset_animations_impl.cc
diff --git a/cc/animation/scroll_offset_animations_impl.cc b/cc/animation/scroll_offset_animations_impl.cc
index 71a96b429f5938cb0c9f20ff6bf95cf88d09c0f9..ccbf2dedfc5e33aaeb3f1390c94c5be74f914014 100644
--- a/cc/animation/scroll_offset_animations_impl.cc
+++ b/cc/animation/scroll_offset_animations_impl.cc
@@ -98,9 +98,11 @@ bool ScrollOffsetAnimationsImpl::ScrollAnimationUpdateTarget(
// t = -delayed_by.
trimmed -= delayed_by;
+ double old_dur = curve->Duration().InMillisecondsF();
curve->UpdateTarget(trimmed.InSecondsF(), new_target);
+ double new_dur = curve->Duration().InMillisecondsF();
- return true;
+ return old_dur != new_dur;
}
void ScrollOffsetAnimationsImpl::ScrollAnimationApplyAdjustment(
« no previous file with comments | « no previous file | cc/trees/layer_tree_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698