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

Unified Diff: third_party/WebKit/Source/platform/animation/WebCompositorAnimationPlayer.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/WebCompositorAnimationPlayer.h
diff --git a/third_party/WebKit/public/platform/WebCompositorAnimationPlayer.h b/third_party/WebKit/Source/platform/animation/WebCompositorAnimationPlayer.h
similarity index 52%
rename from third_party/WebKit/public/platform/WebCompositorAnimationPlayer.h
rename to third_party/WebKit/Source/platform/animation/WebCompositorAnimationPlayer.h
index 92abb1ebfa4732f096abe48da4d0285d328a8a2c..9d6f2788df317789510fefe3474cec144734d002 100644
--- a/third_party/WebKit/public/platform/WebCompositorAnimationPlayer.h
+++ b/third_party/WebKit/Source/platform/animation/WebCompositorAnimationPlayer.h
@@ -5,31 +5,47 @@
#ifndef WebCompositorAnimationPlayer_h
#define WebCompositorAnimationPlayer_h
+#include "base/memory/ref_counted.h"
+#include "base/memory/scoped_ptr.h"
+#include "platform/PlatformExport.h"
+
+namespace cc {
+class AnimationPlayer;
+}
+
namespace blink {
class WebCompositorAnimation;
class WebCompositorAnimationDelegate;
class WebLayer;
+class WebToCCAnimationDelegateAdapter;
// A compositor representation for AnimationPlayer.
-class WebCompositorAnimationPlayer {
+class PLATFORM_EXPORT WebCompositorAnimationPlayer {
public:
- virtual ~WebCompositorAnimationPlayer() { }
+ WebCompositorAnimationPlayer();
+ virtual ~WebCompositorAnimationPlayer();
+
+ cc::AnimationPlayer* animationPlayer() const;
// An animation delegate is notified when animations are started and
// stopped. The WebCompositorAnimationPlayer does not take ownership of the delegate, and it is
// the responsibility of the client to reset the layer's delegate before
// deleting the delegate.
- virtual void setAnimationDelegate(WebCompositorAnimationDelegate*) = 0;
+ virtual void setAnimationDelegate(WebCompositorAnimationDelegate*);
+
+ virtual void attachLayer(WebLayer*);
+ virtual void detachLayer();
esprehn 2016/01/28 03:40:40 does this all need to be virtual still?
+ virtual bool isLayerAttached() const;
- virtual void attachLayer(WebLayer*) = 0;
- virtual void detachLayer() = 0;
- virtual bool isLayerAttached() const = 0;
+ virtual void addAnimation(WebCompositorAnimation*);
+ virtual void removeAnimation(int animationId);
+ virtual void pauseAnimation(int animationId, double timeOffset);
+ virtual void abortAnimation(int animationId);
- virtual void addAnimation(WebCompositorAnimation*) = 0;
- virtual void removeAnimation(int animationId) = 0;
- virtual void pauseAnimation(int animationId, double timeOffset) = 0;
- virtual void abortAnimation(int animationId) = 0;
+private:
+ scoped_refptr<cc::AnimationPlayer> m_animationPlayer;
+ scoped_ptr<WebToCCAnimationDelegateAdapter> m_animationDelegateAdapter;
};
} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698