[Web Animations] Refactor AnimationEffect and KeyframeEffect into AnimationEffectRead...
[WebKit-https.git] / Source / WebCore / animation / KeyframeEffect.idl
index 62f8fd5..393dc1b 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2017 Apple Inc. All rights reserved.
+ * Copyright (C) 2017-2018 Apple Inc. All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
 
 [
     EnabledAtRuntime=WebAnimations,
+    Exposed=Window,
     ConstructorMayThrowException,
     ConstructorCallWith=ScriptState,
     Constructor(Element? target, object? keyframes, optional (unrestricted double or KeyframeEffectOptions) options)
-] interface KeyframeEffect : AnimationEffect {
-    readonly attribute Element? target;
-    attribute IterationCompositeOperation iterationComposite;
-    attribute CompositeOperation composite;
-    [CallWith=ScriptState] sequence<object> getKeyframes();
+] interface KeyframeEffect : KeyframeEffectReadOnly {
+    inherit attribute IterationCompositeOperation iterationComposite;
+    inherit attribute CompositeOperation composite;
     [MayThrowException, CallWith=ScriptState] void setKeyframes(object? keyframes);
 };
-
-dictionary BasePropertyIndexedKeyframe {
-    (sequence<double?> or double?) offset = [];
-    (sequence<DOMString> or DOMString) easing = [];
-    (sequence<CompositeOperation> or CompositeOperation) composite = [];
-};
-
-[
-    JSGenerateToJSObject
-] dictionary BaseComputedKeyframe {
-     double? offset = null;
-     double computedOffset;
-     DOMString easing = "linear";
-     CompositeOperation? composite = null;
-};