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

Unified Diff: cc/animation/scroll_offset_animation_curve.cc

Issue 1734063003: Share animations from compositor to main thread. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix win trybot failure Created 4 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/scroll_offset_animation_curve.h ('k') | cc/blink/web_to_cc_animation_delegate_adapter.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/animation/scroll_offset_animation_curve.cc
diff --git a/cc/animation/scroll_offset_animation_curve.cc b/cc/animation/scroll_offset_animation_curve.cc
index 1f44bbadadcdfe022cdac744314a11c31b0eae96..86448b73b4409c63fcb99163b2776f5489213b6c 100644
--- a/cc/animation/scroll_offset_animation_curve.cc
+++ b/cc/animation/scroll_offset_animation_curve.cc
@@ -134,6 +134,11 @@ AnimationCurve::CurveType ScrollOffsetAnimationCurve::Type() const {
}
scoped_ptr<AnimationCurve> ScrollOffsetAnimationCurve::Clone() const {
+ return CloneToScrollOffsetAnimationCurve();
+}
+
+scoped_ptr<ScrollOffsetAnimationCurve>
+ScrollOffsetAnimationCurve::CloneToScrollOffsetAnimationCurve() const {
scoped_ptr<TimingFunction> timing_function(
static_cast<TimingFunction*>(timing_function_->Clone().release()));
scoped_ptr<ScrollOffsetAnimationCurve> curve_clone =
@@ -142,7 +147,7 @@ scoped_ptr<AnimationCurve> ScrollOffsetAnimationCurve::Clone() const {
curve_clone->total_animation_duration_ = total_animation_duration_;
curve_clone->last_retarget_ = last_retarget_;
curve_clone->has_set_initial_value_ = has_set_initial_value_;
- return std::move(curve_clone);
+ return curve_clone;
}
static double VelocityBasedDurationBound(gfx::Vector2dF old_delta,
« no previous file with comments | « cc/animation/scroll_offset_animation_curve.h ('k') | cc/blink/web_to_cc_animation_delegate_adapter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698