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

Unified Diff: Source/core/dom/EventDispatcher.cpp

Issue 16194013: Mouse press should focus on any types of form controls. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: rebase, common->default, etc. Created 7 years, 6 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: Source/core/dom/EventDispatcher.cpp
diff --git a/Source/core/dom/EventDispatcher.cpp b/Source/core/dom/EventDispatcher.cpp
index 51e7cc127ba1956e91ef06bc499e6d147150772e..dcf5efe05467341334a057c5384e41502e04081b 100644
--- a/Source/core/dom/EventDispatcher.cpp
+++ b/Source/core/dom/EventDispatcher.cpp
@@ -200,6 +200,7 @@ inline void EventDispatcher::dispatchEventPostProcess(void* preDispatchEventHand
// implementation detail and not part of the DOM.
if (!m_event->defaultPrevented() && !m_event->defaultHandled()) {
// Non-bubbling events call only one default event handler, the one for the target.
+ m_node->willCallDefaultEventHandler(*m_event);
m_node->defaultEventHandler(m_event.get());
ASSERT(!m_event->defaultPrevented());
if (m_event->defaultHandled())
@@ -209,6 +210,7 @@ inline void EventDispatcher::dispatchEventPostProcess(void* preDispatchEventHand
if (m_event->bubbles()) {
size_t size = m_event->eventPath().size();
for (size_t i = 1; i < size; ++i) {
+ m_event->eventPath()[i]->node()->willCallDefaultEventHandler(*m_event);
m_event->eventPath()[i]->node()->defaultEventHandler(m_event.get());
ASSERT(!m_event->defaultPrevented());
if (m_event->defaultHandled())

Powered by Google App Engine
This is Rietveld 408576698