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

Unified Diff: third_party/WebKit/Source/core/events/EventTarget.cpp

Issue 1956733002: Remove EventListenerOptions runtime enable setting. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master_add_event_listener_options
Patch Set: Amend unit tests Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/events/EventTarget.cpp
diff --git a/third_party/WebKit/Source/core/events/EventTarget.cpp b/third_party/WebKit/Source/core/events/EventTarget.cpp
index be7d44b56131554be39135e30de53d296a8c9b3a..9343640919d92e56a123d487d2708f822532bacc 100644
--- a/third_party/WebKit/Source/core/events/EventTarget.cpp
+++ b/third_party/WebKit/Source/core/events/EventTarget.cpp
@@ -60,20 +60,8 @@ void setDefaultAddEventListenerOptionsLegacy(AddEventListenerOptions& options, b
options.setPassive(false);
}
-void setDefaultEventListenerOptions(EventListenerOptions& options)
-{
- // The default for capture is based on whether the eventListenerOptions
- // runtime setting is enabled. That is
- // addEventListener('type', function(e) {}, {});
- // behaves differently under the setting. With the setting off
- // capture is true; with the setting on capture is false.
- if (!options.hasCapture())
- options.setCapture(!RuntimeEnabledFeatures::eventListenerOptionsEnabled());
-}
-
void setDefaultAddEventListenerOptions(AddEventListenerOptions& options)
{
- setDefaultEventListenerOptions(options);
if (!options.hasPassive())
options.setPassive(false);
}
@@ -201,7 +189,6 @@ bool EventTarget::removeEventListener(const AtomicString& eventType, const Event
bool EventTarget::removeEventListener(const AtomicString& eventType, const EventListener* listener, EventListenerOptions& options)
{
- setDefaultEventListenerOptions(options);
return removeEventListenerInternal(eventType, listener, options);
}
« no previous file with comments | « third_party/WebKit/Source/core/events/EventListenerOptions.idl ('k') | third_party/WebKit/Source/core/events/EventTarget.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698