Chromium Code Reviews| Index: Source/core/animation/AnimationPlayer.h |
| diff --git a/Source/core/animation/AnimationPlayer.h b/Source/core/animation/AnimationPlayer.h |
| index ea016e22c22c1440b19f96c7720500de6f9c8714..1fc9c09e4d6c0af0787c417e46f380bc9ead7127 100644 |
| --- a/Source/core/animation/AnimationPlayer.h |
| +++ b/Source/core/animation/AnimationPlayer.h |
| @@ -39,6 +39,8 @@ |
| #include "core/dom/DOMException.h" |
| #include "core/events/EventTarget.h" |
| #include "platform/heap/Handle.h" |
| +#include "public/platform/WebCompositorAnimationDelegate.h" |
| +#include "public/platform/WebCompositorAnimationPlayerClient.h" |
| #include "wtf/RefPtr.h" |
| namespace blink { |
| @@ -46,11 +48,14 @@ namespace blink { |
| class AnimationTimeline; |
| class Element; |
| class ExceptionState; |
| +class WebCompositorAnimationPlayer; |
| class AnimationPlayer final |
| - : public EventTargetWithInlineData |
| - , public RefCountedWillBeNoBase<AnimationPlayer> |
| - , public ActiveDOMObject { |
| + : public EventTargetWithInlineData, |
| + public RefCountedWillBeNoBase<AnimationPlayer>, |
| + public ActiveDOMObject, |
| + public WebCompositorAnimationDelegate, |
| + public WebCompositorAnimationPlayerClient { |
| DEFINE_WRAPPERTYPEINFO(); |
| REFCOUNTED_EVENT_TARGET(AnimationPlayer); |
| WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(AnimationPlayer); |
| @@ -149,6 +154,8 @@ public: |
| void setCompositorPending(bool sourceChanged = false); |
| void notifyCompositorStartTime(double timelineTime); |
| void notifyStartTime(double timelineTime); |
| + // WebCompositorAnimationPlayerClient implementation. |
| + WebCompositorAnimationPlayer* compositorPlayer() const override { return m_compositorPlayer.get(); } |
| bool affects(const Element&, CSSPropertyID) const; |
| @@ -183,6 +190,12 @@ private: |
| void beginUpdatingState(); |
| void endUpdatingState(); |
| + void createCompositorPlayer(); |
| + void destroyCompositorPlayer(); |
| + // WebCompositorAnimationDelegate implementation. |
| + void notifyAnimationStarted(double monotonicTime, int group) override; |
| + void notifyAnimationFinished(double monotonicTime, int group) override { } |
|
dstockwell
2015/03/16 00:11:27
We should just not add this.
loyso (OOO)
2015/03/18 06:59:43
I didn't want to change WebCompositorAnimationDele
dstockwell
2015/03/18 07:17:18
Ahh, I see. Are you planning to keep WebCompositor
loyso (OOO)
2015/03/19 02:32:24
It's a part of old system. After the migration we
|
| + |
| AnimationPlayState m_playState; |
| double m_playbackRate; |
| double m_startTime; |
| @@ -258,6 +271,8 @@ private: |
| bool m_compositorPending; |
| int m_compositorGroup; |
| + OwnPtr<WebCompositorAnimationPlayer> m_compositorPlayer; |
| + |
| bool m_currentTimePending; |
| bool m_stateIsBeingUpdated; |