Bug 85819 (RAF_returning_zero)

Summary: Initial call to webkitRequestAnimationFrame returns 0, Spec indicates the handle should always be > 0
Product: WebKit Reporter: ctrlfrk
Component: WebKit APIAssignee: Dean Jackson <dino>
Status: RESOLVED FIXED    
Severity: Minor CC: dino, jamesr, pimvdb, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch jamesr: review+

ctrlfrk
Reported 2012-05-07 12:54:15 PDT
Looking at http://www.w3.org/TR/animation-timing/ there is a section that reads: "The requestAnimationFrame method is used to signal to the user agent that a script-based animation needs to be resampled. When requestAnimationFrame(callback) is called, the user agent must schedule a script-based animation resampling by appending to the end of the animation frame request callback list an entry whose handle is a user-agent-defined integer greater than zero that uniquely identifies the entry in the list and whose callback is callback." However the first call to webkitRequestAnimationFrame seems to be returning a handle of 0. It's minor, but worth mentioning.
Attachments
Patch (3.92 KB, patch)
2012-08-14 18:18 PDT, Dean Jackson
jamesr: review+
Dean Jackson
Comment 1 2012-05-08 13:21:36 PDT
Yeah, easy fix.
James Robinson
Comment 2 2012-05-08 13:33:47 PDT
Whoops! Pre-increment when it should be a post-increment. For the record, the intent of that text is that the return value should never be false-y and it should match setTimeout/setInterval
Radar WebKit Bug Importer
Comment 3 2012-08-14 17:13:58 PDT
Dean Jackson
Comment 4 2012-08-14 18:18:01 PDT
Dean Jackson
Comment 5 2012-08-14 18:52:21 PDT
Note You need to log in before you can comment on or make changes to this bug.