WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED WORKSFORME
33106
'load' events fire with event.eventPhase set to '0' instead of '2' AT_TARGET
https://bugs.webkit.org/show_bug.cgi?id=33106
Summary
'load' events fire with event.eventPhase set to '0' instead of '2' AT_TARGET
Diego Perini
Reported
2010-01-02 09:39:20 PST
I tested this both on Safari Version 4.0.4 (6531.21.10) and Version 3.1.2 (5525.20.1) I noticed that the 'load' event will fire with event.eventPhase set to '0' instead of '2' AT_TARGET. This happens in Safari both using DOM2 or DOM0 registration. Doesn't happen in any other tested browser. Simple test I used: DOM2 window.addEventListener('load', function(e) { alert("event.eventPhase: " + e.eventPhase + "\nphase should be: 2"); }, false); DOM0 window.onload = function(e) { alert("event.eventPhase: " + e.eventPhase + "\nphase should be: 2"); }; from what I understand the possible values are 1, 2 and 3 ... If I recall 0 was for custom events.
Attachments
Add attachment
proposed patch, testcase, etc.
Alexey Proskuryakov
Comment 1
2010-01-02 11:50:36 PST
I can reproduce with shipping Safari/WebKit, but not with a ToT WebKit build - possibly fixed in <
http://trac.webkit.org/changeset/48701
>. Please test with a nightly build from <
http://nightly.webkit.org
>.
Diego Perini
Comment 2
2010-01-02 13:31:49 PST
Alexey, that was fast ;-) Solves for me, when the 'load' event fires on window object, 'eventPhase' property is now correctly AT_TARGET (2). Tested with nightly build (
r52686
). Thank you for your precious help.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug