@@ -1245,7 +1245,8 @@ as CSS Animations [[CSS-ANIMATIONS-1]].
12451245 implementations:
12461246
12471247 <div class='example'><pre class='lang-javascript'>
1248- animation.play().then(
1248+ animation.play();
1249+ animation.ready.then(
12491250 () => { console.log('Playback commenced' ); },
12501251 () => { console.log('Playback was canceled' ); }
12511252 );
@@ -3952,10 +3953,10 @@ interface Animation : EventTarget {
39523953 attribute EventHandler oncancel;
39533954 void cancel ();
39543955 void finish ();
3955- Promise<Animation> play ();
3956- Promise<Animation> pause ();
3957- Promise<Animation> updatePlaybackRate (double playbackRate);
3958- Promise<Animation> reverse ();
3956+ void play ();
3957+ void pause ();
3958+ void updatePlaybackRate (double playbackRate);
3959+ void reverse ();
39593960};
39603961</pre>
39613962
@@ -4070,46 +4071,35 @@ interface Animation : EventTarget {
40704071
40714072 </div>
40724073
4073- : <dfn method for=Animation lt='play()'>Promise<Animation> play()</dfn>
4074- :: Begins or resumes playback of the animation by running the procedure to
4075- [=play an animation=] passing true as the value of the |auto-rewind| flag.
4076-
4077- Returns the animation's [=current finished promise=] at the moment
4078- immediately after performing the [=play an animation=] procedure.
4079- : <dfn method for=Animation lt='pause()'>Promise<Animation> pause()</dfn>
4074+ : <dfn method for=Animation lt='play()'>void play()</dfn>
4075+ :: Unpauses the animation and rewinds if it has finished playing using
4076+ the procedure to <a>play an animation</a> for this object
4077+ with the <var> auto-rewind</var> flag set to true.
4078+ : <dfn method for=Animation lt='pause()'>void pause()</dfn>
40804079:: Suspends the playback of this animation by running the procedure to
40814080 <a>pause an animation</a> for this object.
4082-
4083- Returns the animation's [=current ready promise=] at the moment
4084- immediately after performing the [=pause an animation=] procedure.
4085- : <dfn method for=Animation lt='updatePlaybackRate(playbackRate)'>Promise<Animation> updatePlaybackRate(playbackRate)</dfn>
4081+ : <dfn method for=Animation lt='updatePlaybackRate(playbackRate)'>void updatePlaybackRate(playbackRate)</dfn>
40864082:: Performs an asynchronous update of the [=playback rate=] of this
40874083 animation by performing the [=seamlessly update the playback rate=]
40884084 procedure, passing
40894085 {{Animation/updatePlaybackRate(playbackRate)/playbackRate}} as the |new
40904086 playback rate|.
40914087
4092- Returns the animation's [=current ready promise=] at the moment immediately
4093- after performing the [=seamlessly update the playback rate=] procedure.
4094-
40954088 <div class="parameters">
40964089
40974090 : <dfn argument for="Animation/updatePlaybackRate(playbackRate)"
40984091 lt="playbackRate"> playbackRate</dfn>
40994092 :: A finite real number specifying the updated playback rate to use.
41004093
41014094 </div>
4102- : <dfn method for=Animation lt='reverse()'>Promise<Animation> reverse()</dfn>
4095+ : <dfn method for=Animation lt='reverse()'>void reverse()</dfn>
41034096:: Inverts the [=playback rate=] of this animation and plays it using the
41044097 <a>reverse an animation</a> procedure for this object.
41054098 As with <a method for=Animation lt="play()">play()</a> , this
41064099 method unpauses the animation and, if the animation has already finished
41074100 playing in the reversed direction, seeks to the start of the <a>target
41084101 effect</a> .
41094102
4110- Returns the animation's [=current finished promise=] at the moment
4111- immediately after performing the [=reverse an animation=] procedure.
4112-
41134103</div>
41144104
41154105<h4 id="the-animationplaystate-enumeration">The <code>AnimationPlayState</code> enumeration</h4>
@@ -5969,10 +5959,6 @@ The following changes have been made since the <a
59695959 {{AnimationEffect/updateTiming}} method.
59705960 * Removed <code> KeyframeEffectReadOnly</code> , leaving only
59715961 {{KeyframeEffect}} .
5972- * Made the {{Animation/play()}} and {{Animation/reverse()}} methods on
5973- {{Animation}} return the animation's [=current finished promise=] ,
5974- and the {{Animation/pause()}} and {{Animation/updatePlaybackRate()}} methods
5975- return the animation's [=current ready promise=] .
59765962* Added special handling to allow animating the 'offset' property from the
59775963 programming interface using <code> cssOffset</code> to avoid conflict with
59785964 the attribute name used to specify keyframe offsets.
0 commit comments