Re: [RequestAnimationFrame] Canceling animation frame requests from animation frame callbacks may not work

On Thu, Jan 12, 2012 at 8:23 PM, Boris Zbarsky <bzbarsky@mit.edu> wrote:

> On 12/8/11 5:54 PM, James Robinson wrote:
>
>> I've pushed https://dvcs.w3.org/hg/**webperf/rev/a43340fd9097<https://dvcs.w3.org/hg/webperf/rev/a43340fd9097>,
>> viewable at
>> https://dvcs.w3.org/hg/**webperf/raw-file/a43340fd9097/**
>> specs/RequestAnimationFrame/**Overview.html<https://dvcs.w3.org/hg/webperf/raw-file/a43340fd9097/specs/RequestAnimationFrame/Overview.html>
>> ,
>> which I believe fixes this issue.  I've made the cancelled flag a
>> property of the callback itself rather than state carried along on the
>> side and clarified that cancelAnimationFrame() sets this flag regardless
>> of whether the callback is in any document's animation list or not.
>>
>> It's possible that I've flubbed something here, please let me know if so.
>>
>
> Looks pretty reasonable, though there's a missing "no" between "is" and
> "callback" in "If there is callback with the given handle, then this
> function does nothing."


Oops, I accidentally an entire word.  I also noticed that in this section
it's not clear that clear..() will only cancel callbacks on the same
context that the request..() call was made on, since I expect handles to
overlap across different documents.
https://dvcs.w3.org/hg/webperf/rev/2efaa170f819 pushed to fix these two
things.

- James

>
>
> -Boris
>

Received on Friday, 13 January 2012 11:54:41 UTC