WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
148800
dispatchEvent() should throw an InvalidStateError if the event's initialized flag is not set
https://bugs.webkit.org/show_bug.cgi?id=148800
Summary
dispatchEvent() should throw an InvalidStateError if the event's initialized ...
Chris Dumez
Reported
2015-09-04 09:59:42 PDT
dispatchEvent() should throw an InvalidStateError if the event's initialized flag is not set, and should allow dispatching events with an empty type as long as it is initialized:
https://dom.spec.whatwg.org/#dom-eventtarget-dispatchevent
(step 1) Currently, WebKit relies on the event type being empty and throws a UNSPECIFIED_EVENT_TYPE_ERR: DOM Events Exception 0. This is covered by the following newly imported W3C test: http/tests/w3c/dom/events/EventTarget-dispatchEvent.html
Attachments
Patch
(28.14 KB, patch)
2015-09-04 10:48 PDT
,
Chris Dumez
no flags
Details
Formatted Diff
Diff
Patch
(28.45 KB, patch)
2015-09-05 11:07 PDT
,
Chris Dumez
no flags
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Chris Dumez
Comment 1
2015-09-04 10:00:35 PDT
rdar://problem/22565782
rdar://problem/22565485
Chris Dumez
Comment 2
2015-09-04 10:48:02 PDT
Created
attachment 260597
[details]
Patch
Geoffrey Garen
Comment 3
2015-09-04 13:53:27 PDT
Comment on
attachment 260597
[details]
Patch r=me
WebKit Commit Bot
Comment 4
2015-09-04 14:13:14 PDT
Comment on
attachment 260597
[details]
Patch Clearing flags on attachment: 260597 Committed
r189386
: <
http://trac.webkit.org/changeset/189386
>
WebKit Commit Bot
Comment 5
2015-09-04 14:13:24 PDT
All reviewed patches have been landed. Closing bug.
Alexey Proskuryakov
Comment 6
2015-09-04 22:23:16 PDT
This change appears to have made several tests assert, rolling out.
https://build.webkit.org/results/Apple%20Yosemite%20Debug%20WK2%20(Tests)/r189417%20(6763)/results.html
WebKit Commit Bot
Comment 7
2015-09-04 22:25:06 PDT
Re-opened since this is blocked by
bug 148883
Chris Dumez
Comment 8
2015-09-05 11:07:25 PDT
Created
attachment 260694
[details]
Patch
Chris Dumez
Comment 9
2015-09-05 11:08:20 PDT
Comment on
attachment 260694
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=260694&action=review
> Source/WebCore/dom/EventTarget.cpp:-194 > - ASSERT(event && !event->type().isEmpty());
Fixed outdated assertion as it is now valid to dispatch an event with an empty type, as long as the event has its initialized flag set to true.
WebKit Commit Bot
Comment 10
2015-09-06 13:41:56 PDT
Comment on
attachment 260694
[details]
Patch Clearing flags on attachment: 260694 Committed
r189452
: <
http://trac.webkit.org/changeset/189452
>
WebKit Commit Bot
Comment 11
2015-09-06 13:42:01 PDT
All reviewed patches have been landed. Closing bug.
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