Bug 19468 - Unable to dispatch Window load and unload events
Summary: Unable to dispatch Window load and unload events
Status: UNCONFIRMED
Alias: None
Product: WebKit
Classification: Unclassified
Component: DOM (show other bugs)
Version: 525.x (Safari 3.1)
Hardware: PC Windows XP
: P2 Normal
Assignee: Nobody
URL: http://weston.ruter.net/projects/test...
Keywords:
Depends on:
Blocks:
 
Reported: 2008-06-10 14:03 PDT by Weston Ruter
Modified: 2008-06-10 15:31 PDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Weston Ruter 2008-06-10 14:03:47 PDT
Both Firefox 2/3 and Opera 9.26 are able to dispatch load and unload events on the Window. In Safari 3.1.1, however, there exists no function window.dispatchEvent(). I attempted a workaround by creating and initializing load and unload events which bubble (they are specified not to bubble) and then dispatching these on the documentElement with the hope that they would bubble up to the Window, and this does work, but only for unload events. In Safari there is no way to fire Window load events unless the traditional event model is employed and window.onload() is envoked. It would seem that Safari's behavior should be brought into line with Firefox and Opera's.

See associated URL for examples.