diff options
author | cpu@chromium.org <cpu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-10-10 18:30:03 +0000 |
---|---|---|
committer | cpu@chromium.org <cpu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-10-10 18:30:03 +0000 |
commit | f49929630e92c553a0ab4f12d800e2ac3a7d689b (patch) | |
tree | c5d12627b2e697fc060fa469ced69dc1171424e2 /cc/CCKeyframedAnimationCurve.h | |
parent | 677649e4c49946f36a94fac2affee9eab218b812 (diff) | |
download | chromium_src-f49929630e92c553a0ab4f12d800e2ac3a7d689b.zip chromium_src-f49929630e92c553a0ab4f12d800e2ac3a7d689b.tar.gz chromium_src-f49929630e92c553a0ab4f12d800e2ac3a7d689b.tar.bz2 |
Revert 161133 - [cc] Use base ptr types for cc's CSS animation classes
Relanding https://codereview.chromium.org/11078009/
TBR=jamesr
BUG=154451
Review URL: https://chromiumcodereview.appspot.com/11085029
TBR=enne@chromium.org
Review URL: https://codereview.chromium.org/11086053
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@161135 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'cc/CCKeyframedAnimationCurve.h')
-rw-r--r-- | cc/CCKeyframedAnimationCurve.h | 36 |
1 files changed, 19 insertions, 17 deletions
diff --git a/cc/CCKeyframedAnimationCurve.h b/cc/CCKeyframedAnimationCurve.h index 066e5c6..33cee77 100644 --- a/cc/CCKeyframedAnimationCurve.h +++ b/cc/CCKeyframedAnimationCurve.h @@ -7,8 +7,10 @@ #include "CCAnimationCurve.h" #include "CCTimingFunction.h" -#include "scoped_ptr_vector.h" +#include "cc/own_ptr_vector.h" #include <public/WebTransformOperations.h> +#include <wtf/OwnPtr.h> +#include <wtf/PassOwnPtr.h> namespace cc { @@ -18,40 +20,40 @@ public: const CCTimingFunction* timingFunction() const; protected: - CCKeyframe(double time, scoped_ptr<CCTimingFunction>); + CCKeyframe(double time, PassOwnPtr<CCTimingFunction>); virtual ~CCKeyframe(); private: double m_time; - scoped_ptr<CCTimingFunction> m_timingFunction; + OwnPtr<CCTimingFunction> m_timingFunction; }; class CCFloatKeyframe : public CCKeyframe { public: - static scoped_ptr<CCFloatKeyframe> create(double time, float value, scoped_ptr<CCTimingFunction>); + static PassOwnPtr<CCFloatKeyframe> create(double time, float value, PassOwnPtr<CCTimingFunction>); virtual ~CCFloatKeyframe(); float value() const; - scoped_ptr<CCFloatKeyframe> clone() const; + PassOwnPtr<CCFloatKeyframe> clone() const; private: - CCFloatKeyframe(double time, float value, scoped_ptr<CCTimingFunction>); + CCFloatKeyframe(double time, float value, PassOwnPtr<CCTimingFunction>); float m_value; }; class CCTransformKeyframe : public CCKeyframe { public: - static scoped_ptr<CCTransformKeyframe> create(double time, const WebKit::WebTransformOperations& value, scoped_ptr<CCTimingFunction>); + static PassOwnPtr<CCTransformKeyframe> create(double time, const WebKit::WebTransformOperations& value, PassOwnPtr<CCTimingFunction>); virtual ~CCTransformKeyframe(); const WebKit::WebTransformOperations& value() const; - scoped_ptr<CCTransformKeyframe> clone() const; + PassOwnPtr<CCTransformKeyframe> clone() const; private: - CCTransformKeyframe(double time, const WebKit::WebTransformOperations& value, scoped_ptr<CCTimingFunction>); + CCTransformKeyframe(double time, const WebKit::WebTransformOperations& value, PassOwnPtr<CCTimingFunction>); WebKit::WebTransformOperations m_value; }; @@ -59,15 +61,15 @@ private: class CCKeyframedFloatAnimationCurve : public CCFloatAnimationCurve { public: // It is required that the keyframes be sorted by time. - static scoped_ptr<CCKeyframedFloatAnimationCurve> create(); + static PassOwnPtr<CCKeyframedFloatAnimationCurve> create(); virtual ~CCKeyframedFloatAnimationCurve(); - void addKeyframe(scoped_ptr<CCFloatKeyframe>); + void addKeyframe(PassOwnPtr<CCFloatKeyframe>); // CCAnimationCurve implementation virtual double duration() const OVERRIDE; - virtual scoped_ptr<CCAnimationCurve> clone() const OVERRIDE; + virtual PassOwnPtr<CCAnimationCurve> clone() const OVERRIDE; // CCFloatAnimationCurve implementation virtual float getValue(double t) const OVERRIDE; @@ -77,21 +79,21 @@ private: // Always sorted in order of increasing time. No two keyframes have the // same time. - ScopedPtrVector<CCFloatKeyframe> m_keyframes; + OwnPtrVector<CCFloatKeyframe> m_keyframes; }; class CCKeyframedTransformAnimationCurve : public CCTransformAnimationCurve { public: // It is required that the keyframes be sorted by time. - static scoped_ptr<CCKeyframedTransformAnimationCurve> create(); + static PassOwnPtr<CCKeyframedTransformAnimationCurve> create(); virtual ~CCKeyframedTransformAnimationCurve(); - void addKeyframe(scoped_ptr<CCTransformKeyframe>); + void addKeyframe(PassOwnPtr<CCTransformKeyframe>); // CCAnimationCurve implementation virtual double duration() const OVERRIDE; - virtual scoped_ptr<CCAnimationCurve> clone() const OVERRIDE; + virtual PassOwnPtr<CCAnimationCurve> clone() const OVERRIDE; // CCTransformAnimationCurve implementation virtual WebKit::WebTransformationMatrix getValue(double t) const OVERRIDE; @@ -101,7 +103,7 @@ private: // Always sorted in order of increasing time. No two keyframes have the // same time. - ScopedPtrVector<CCTransformKeyframe> m_keyframes; + OwnPtrVector<CCTransformKeyframe> m_keyframes; }; } // namespace cc |