[whatwg] Asynchronous events observe unexpected states in media elements
Boris Zbarsky
bzbarsky at MIT.EDU
Thu Apr 9 18:54:51 PDT 2009
Robert O'Callahan wrote:
> A related surprise is that although a media element delays the document
> load event until the readyState reaches HAVE_CURRENT_DATA, it is
> possible for a loadeddata event handler to actually run after the
> document load event handler.
For what it's worth, there are similar situations elsewhere. For
example, the currently proposed spec for stylesheet load events says
those fire asynchronously, so it looks to me like they could fire after
onload.
The only place in Gecko where we currently fire asynchronous load-like
events is for HTML <img>; we make sure to fire the page's onload after
all image onloads, even though the image onloads fire async from image
load completion.
Perhaps this should be a general rule for load events of various sorts.
This doesn't help your other issues, of course.
-Boris
More information about the whatwg
mailing list