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

Unified Diff: third_party/WebKit/Source/platform/animation/WebScrollOffsetAnimationCurve.h

Issue 1616653002: CC Animation: Move files from cc_blink to Source/platform/animation (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix ScrollAnimatorCompositorCoordinator for MSVC. Created 4 years, 11 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: third_party/WebKit/Source/platform/animation/WebScrollOffsetAnimationCurve.h
diff --git a/third_party/WebKit/Source/platform/animation/WebScrollOffsetAnimationCurve.h b/third_party/WebKit/Source/platform/animation/WebScrollOffsetAnimationCurve.h
new file mode 100644
index 0000000000000000000000000000000000000000..10e149a6147ef1499f4158661a6c564b2c981bca
--- /dev/null
+++ b/third_party/WebKit/Source/platform/animation/WebScrollOffsetAnimationCurve.h
@@ -0,0 +1,48 @@
+// Copyright 2014 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef WebScrollOffsetAnimationCurve_h
+#define WebScrollOffsetAnimationCurve_h
+
+#include "base/memory/scoped_ptr.h"
+#include "platform/PlatformExport.h"
+#include "platform/animation/WebCompositorAnimationCurve.h"
+#include "public/platform/WebFloatPoint.h"
+
+namespace cc {
+class AnimationCurve;
+class ScrollOffsetAnimationCurve;
+}
+
+namespace blink {
+
+class PLATFORM_EXPORT WebScrollOffsetAnimationCurve : public WebCompositorAnimationCurve {
+public:
+ enum ScrollDurationBehavior {
+ ScrollDurationDeltaBased = 0,
+ ScrollDurationConstant,
+ ScrollDurationInverseDelta
+ };
+
+ WebScrollOffsetAnimationCurve(blink::WebFloatPoint, TimingFunctionType, ScrollDurationBehavior);
esprehn 2016/01/28 03:40:40 no need to put blink:: on stuff in here
loyso (OOO) 2016/01/28 07:10:09 Done.
+ ~WebScrollOffsetAnimationCurve() override;
+
+ // WebCompositorAnimationCurve implementation.
+ AnimationCurveType type() const override;
+
+ virtual void setInitialValue(WebFloatPoint);
+ virtual WebFloatPoint getValue(double time) const;
+ virtual double duration() const;
+ virtual WebFloatPoint targetValue() const;
+ virtual void updateTarget(double time, WebFloatPoint newTarget);
+
+ scoped_ptr<cc::AnimationCurve> CloneToAnimationCurve() const;
+
+private:
+ scoped_ptr<cc::ScrollOffsetAnimationCurve> m_curve;
+};
+
+} // namespace blink
+
+#endif // WebScrollOffsetAnimationCurve_h

Powered by Google App Engine
This is Rietveld 408576698