Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1016)

Issue 1233233003: Add Event.isTrusted support (Closed)

Created:
5 years, 5 months ago by dtapuska
Modified:
5 years, 5 months ago
Reviewers:
tkent, Yuki
CC:
blink-reviews, blink-reviews-w3ctests_chromium.org, vivekg, sof, eae+blinkwatch, blink-reviews-dom_chromium.org, dglazkov+blink, vivekg_samsung, Inactive, rwlbuis
Base URL:
https://chromium.googlesource.com/chromium/blink.git@master_event_trusted_main2
Target Ref:
refs/heads/master
Project:
blink
Visibility:
Public.

Description

Add Event.isTrusted support Add the Event.isTrusted support behind an TrustedEvents experimental feature flag. The trusted flag is set at the point of event dispatch just before any event processing on the event takes place. There are 5 spots where the trusted events are set 1) EventTarget::eventDispatch (from C++) 2) EventTarget::eventDispatchForBindings (from JS) 3) LocalDOMWindow::dispatchEvent (from C++) with special semantics about target 4) SimulatedMouseEvent constructor (these events are generated by the EventDispatcher itself) 5) Node::dispatchScopedEvent Intent to Ship: https://groups.google.com/a/chromium.org/forum/#!topic/blink-dev/cEJvjWg9bqg BUG=334015 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=199071

Patch Set 1 #

Patch Set 2 : Add back Unforgeable #

Total comments: 12

Patch Set 3 : Fix nits #

Unified diffs Side-by-side diffs Delta from patch set Stats (+83 lines, -46 lines) Patch
A LayoutTests/fast/events/event-trusted.html View 1 2 1 chunk +46 lines, -0 lines 0 comments Download
A LayoutTests/fast/events/event-trusted-expected.txt View 1 chunk +19 lines, -0 lines 0 comments Download
M LayoutTests/fast/xmlhttprequest/xmlhttprequest-get-expected.txt View 1 chunk +1 line, -0 lines 0 comments Download
M LayoutTests/imported/web-platform-tests/html/editing/focus/focus-management/focus-events-expected.txt View 1 2 1 chunk +0 lines, -5 lines 0 comments Download
M LayoutTests/imported/web-platform-tests/html/semantics/forms/textfieldselection/select-event-expected.txt View 1 2 1 chunk +0 lines, -9 lines 0 comments Download
M LayoutTests/imported/web-platform-tests/html/semantics/forms/the-button-element/button-events-expected.txt View 1 chunk +2 lines, -2 lines 0 comments Download
M LayoutTests/imported/web-platform-tests/html/semantics/forms/the-input-element/checkbox-expected.txt View 1 chunk +1 line, -1 line 0 comments Download
M LayoutTests/imported/web-platform-tests/html/semantics/forms/the-input-element/radio-expected.txt View 1 chunk +1 line, -1 line 0 comments Download
M LayoutTests/imported/web-platform-tests/html/semantics/interactive-elements/the-details-element/toggleEvent-expected.txt View 1 2 1 chunk +0 lines, -9 lines 0 comments Download
M LayoutTests/imported/web-platform-tests/html/syntax/parsing/the-end-expected.txt View 1 2 1 chunk +0 lines, -6 lines 0 comments Download
M Source/bindings/scripts/v8_attributes.py View 1 1 chunk +1 line, -1 line 0 comments Download
M Source/core/dom/Node.cpp View 2 chunks +1 line, -1 line 0 comments Download
M Source/core/events/Event.h View 1 2 chunks +4 lines, -0 lines 0 comments Download
M Source/core/events/Event.cpp View 1 2 chunks +2 lines, -0 lines 0 comments Download
M Source/core/events/Event.idl View 1 2 1 chunk +1 line, -2 lines 0 comments Download
M Source/core/events/EventTarget.cpp View 1 2 1 chunk +2 lines, -0 lines 0 comments Download
M Source/core/events/MouseEvent.h View 1 2 chunks +0 lines, -6 lines 0 comments Download
M Source/core/events/MouseEvent.cpp View 1 3 chunks +0 lines, -3 lines 0 comments Download
M Source/core/frame/LocalDOMWindow.cpp View 1 chunk +1 line, -0 lines 0 comments Download
M Source/platform/RuntimeEnabledFeatures.in View 1 2 1 chunk +1 line, -0 lines 0 comments Download

Dependent Patchsets:

Messages

Total messages: 15 (4 generated)
dtapuska
5 years, 5 months ago (2015-07-14 21:39:54 UTC) #2
dtapuska
+yukishiino Not sure if this is the correct approach as I had to add the ...
5 years, 5 months ago (2015-07-14 21:42:22 UTC) #4
Yuki
On 2015/07/14 21:42:22, Dave Tapuska wrote: > +yukishiino > > Not sure if this is ...
5 years, 5 months ago (2015-07-15 06:17:52 UTC) #5
dtapuska
On 2015/07/15 06:17:52, Yuki wrote: > On 2015/07/14 21:42:22, Dave Tapuska wrote: > > +yukishiino ...
5 years, 5 months ago (2015-07-15 22:46:07 UTC) #6
dtapuska
On 2015/07/15 22:46:07, Dave Tapuska wrote: > On 2015/07/15 06:17:52, Yuki wrote: > > On ...
5 years, 5 months ago (2015-07-15 22:46:23 UTC) #7
tkent
https://codereview.chromium.org/1233233003/diff/20001/LayoutTests/fast/events/event-trusted.html File LayoutTests/fast/events/event-trusted.html (right): https://codereview.chromium.org/1233233003/diff/20001/LayoutTests/fast/events/event-trusted.html#newcode5 LayoutTests/fast/events/event-trusted.html:5: description("This tests that isTrusted returns the correct value under ...
5 years, 5 months ago (2015-07-16 03:29:37 UTC) #8
Yuki
lgtm for bindings.
5 years, 5 months ago (2015-07-16 05:09:33 UTC) #9
dtapuska
https://codereview.chromium.org/1233233003/diff/20001/LayoutTests/fast/events/event-trusted.html File LayoutTests/fast/events/event-trusted.html (right): https://codereview.chromium.org/1233233003/diff/20001/LayoutTests/fast/events/event-trusted.html#newcode5 LayoutTests/fast/events/event-trusted.html:5: description("This tests that isTrusted returns the correct value under ...
5 years, 5 months ago (2015-07-16 14:48:22 UTC) #10
tkent
lgtm
5 years, 5 months ago (2015-07-16 23:33:32 UTC) #12
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1233233003/40001
5 years, 5 months ago (2015-07-16 23:34:19 UTC) #14
commit-bot: I haz the power
5 years, 5 months ago (2015-07-17 01:33:04 UTC) #15
Message was sent while issue was closed.
Committed patchset #3 (id:40001) as
https://src.chromium.org/viewvc/blink?view=rev&revision=199071

Powered by Google App Engine
This is Rietveld 408576698