Skip to content

[html] Add test that cancelAnimationFrame cancels a pending animation frame callback - #15455

Merged
annevk merged 1 commit into
web-platform-tests:masterfrom
birtles:cancel-pending-callback
Feb 19, 2019
Merged

annevk merged 1 commit into
web-platform-tests:masterfrom
birtles:cancel-pending-callback

Conversation

@birtles

@birtles birtles commented Feb 19, 2019

Copy link
Copy Markdown
Contributor

@birtles

birtles commented Feb 19, 2019

Copy link
Copy Markdown
Contributor Author

I confirmed that this test fails in Firefox and passes in Chrome.

@wpt-pr-bot

Copy link
Copy Markdown
Collaborator

There are no reviewers for this pull request. Please reach out on W3C's irc server (irc.w3.org, port 6665) on channel #testing (web client) to get help with this. Thank you!

@jakearchibald jakearchibald left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@annevk
annevk merged commit bbbe615 into web-platform-tests:master Feb 19, 2019
annevk pushed a commit to whatwg/html that referenced this pull request Feb 19, 2019
Calling cancelAnimationFrame() from within a requestAnimationFrame()
callback should cancel any animation frame callbacks that are
pending for the current frame. The currently specified behavior does not
permit that, however, since it clones the set of callbacks before
iterating over them.

This patch updates the algorithm to run animation frame callbacks such
that it is possible to cancel a pending animation frame callback.
This also brings the specified behavior into line with its
implementation in Blink, EdgeHTML, and WebKit.

Tests: web-platform-tests/wpt#15455.

Closes #4359.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants