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

Unified Diff: third_party/WebKit/Source/modules/compositorworker/WorkletAnimation.h

Issue 2869183002: Initial implementation of WorkletAnimation (Closed)
Patch Set: Make WorkletAnimation subclass Animation Created 3 years, 7 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/modules/compositorworker/WorkletAnimation.h
diff --git a/third_party/WebKit/Source/modules/compositorworker/WorkletAnimation.h b/third_party/WebKit/Source/modules/compositorworker/WorkletAnimation.h
new file mode 100644
index 0000000000000000000000000000000000000000..b5a14623a13211c8382f43998fa80e031417966d
--- /dev/null
+++ b/third_party/WebKit/Source/modules/compositorworker/WorkletAnimation.h
@@ -0,0 +1,48 @@
+// Copyright 2017 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 WorkletAnimation_h
+#define WorkletAnimation_h
+
+#include "bindings/core/v8/serialization/SerializedScriptValue.h"
+#include "bindings/modules/v8/DocumentTimelineOrScrollTimeline.h"
+#include "core/animation/AnimationTimeline.h"
+#include "core/animation/KeyframeEffectReadOnly.h"
+#include "modules/ModulesExport.h"
+#include "platform/bindings/ScriptWrappable.h"
+
+namespace blink {
+
+class MODULES_EXPORT WorkletAnimation : public Animation {
+ DEFINE_WRAPPERTYPEINFO();
+
+ public:
+ static WorkletAnimation* Create(
+ String animator_name,
+ const HeapVector<Member<KeyframeEffectReadOnly>>&,
+ HeapVector<DocumentTimelineOrScrollTimeline>&,
+ RefPtr<SerializedScriptValue>,
+ ExceptionState&);
+
+ virtual ~WorkletAnimation() {}
+
+ DECLARE_VIRTUAL_TRACE();
+
+ private:
+ WorkletAnimation(ExecutionContext*,
+ AnimationTimeline&,
+ String animator_name,
+ const HeapVector<Member<KeyframeEffectReadOnly>>&,
+ HeapVector<DocumentTimelineOrScrollTimeline>&,
+ RefPtr<SerializedScriptValue>);
+
+ String animator_name_;
+ const HeapVector<Member<KeyframeEffectReadOnly>>& effects_;
+ HeapVector<DocumentTimelineOrScrollTimeline>& timelines_;
+ RefPtr<SerializedScriptValue> user_data_;
+};
+
+} // namespace blink
+
+#endif

Powered by Google App Engine
This is Rietveld 408576698