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

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

Issue 2186823002: Do not call an event listener on a cloned node in svg <use>'s UA shadow tree (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: skip timeout test Created 4 years, 4 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/EventListenerMap.cpp
diff --git a/third_party/WebKit/Source/core/events/EventListenerMap.cpp b/third_party/WebKit/Source/core/events/EventListenerMap.cpp
index ef3d5b303e7758f5fd955f9a1587a890bfedb65a..56d5219d1ed6436fc1092c5ec60b6fa56fd09df4 100644
--- a/third_party/WebKit/Source/core/events/EventListenerMap.cpp
+++ b/third_party/WebKit/Source/core/events/EventListenerMap.cpp
@@ -179,25 +179,6 @@ EventListenerVector* EventListenerMap::find(const AtomicString& eventType)
return nullptr;
}
-static void copyListenersNotCreatedFromMarkupToTarget(const AtomicString& eventType, EventListenerVector* listenerVector, EventTarget* target)
-{
- for (auto& eventListener : *listenerVector) {
- // Event listeners created from markup have already been transfered to the shadow tree during cloning.
- if (eventListener.listener()->wasCreatedFromMarkup())
- continue;
- AddEventListenerOptionsResolved options = eventListener.options();
- target->addEventListener(eventType, eventListener.listener(), options);
- }
-}
-
-void EventListenerMap::copyEventListenersNotCreatedFromMarkupToTarget(EventTarget* target)
-{
- assertNoActiveIterators();
-
- for (const auto& eventListener : m_entries)
- copyListenersNotCreatedFromMarkupToTarget(eventListener.first, eventListener.second.get(), target);
-}
-
DEFINE_TRACE(EventListenerMap)
{
visitor->trace(m_entries);
« no previous file with comments | « third_party/WebKit/Source/core/events/EventListenerMap.h ('k') | third_party/WebKit/Source/core/events/EventPath.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698