[Webkit-unassigned] [Bug 142954] New: img load event forgets img target when passed through Promise
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Sun Mar 22 18:40:37 PDT 2015
https://bugs.webkit.org/show_bug.cgi?id=142954
Bug ID: 142954
Summary: img load event forgets img target when passed through
Promise
Classification: Unclassified
Product: WebKit
Version: 528+ (Nightly build)
Hardware: Unspecified
OS: Unspecified
Status: NEW
Severity: Normal
Priority: P2
Component: HTML Events
Assignee: webkit-unassigned at lists.webkit.org
Reporter: bbirch at aconex.com
Wrapping image loading in a Promise does not work as expected.
After the image load event fires event.target contains a IMG element
When the promise is resolved event.target is null
It can be worked around by resolving the promise with event.target rather than event
Here is a demonstration
http://jsfiddle.net/8ys0dn4x/1/
Fails in Safari and webkit nightly
In Firefox the code works as expected
In Chrome there is also a bug, however it is slightly different in that the last promise to resolve in a group still remembers the target, but others are null
Here is a variation on the demonstration
http://jsfiddle.net/d13sf3f2/5/
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20150323/c014e3b8/attachment-0002.html>
More information about the webkit-unassigned
mailing list