| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
| 4 * (C) 2001 Dirk Mueller (mueller@kde.org) | 4 * (C) 2001 Dirk Mueller (mueller@kde.org) |
| 5 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All | 5 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All |
| 6 * rights reserved. | 6 * rights reserved. |
| 7 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) | 7 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) |
| 8 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. | 8 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. |
| 9 * (http://www.torchmobile.com/) | 9 * (http://www.torchmobile.com/) |
| 10 * Copyright (C) 2011 Google Inc. All rights reserved. | 10 * Copyright (C) 2011 Google Inc. All rights reserved. |
| (...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 155 if (dispatchEventAtTarget() == ContinueDispatching) | 155 if (dispatchEventAtTarget() == ContinueDispatching) |
| 156 dispatchEventAtBubbling(); | 156 dispatchEventAtBubbling(); |
| 157 } | 157 } |
| 158 } | 158 } |
| 159 dispatchEventPostProcess(preDispatchEventHandlerResult); | 159 dispatchEventPostProcess(preDispatchEventHandlerResult); |
| 160 | 160 |
| 161 // Ensure that after event dispatch, the event's target object is the | 161 // Ensure that after event dispatch, the event's target object is the |
| 162 // outermost shadow DOM boundary. | 162 // outermost shadow DOM boundary. |
| 163 m_event->setTarget(m_event->eventPath().windowEventContext().target()); | 163 m_event->setTarget(m_event->eventPath().windowEventContext().target()); |
| 164 m_event->setCurrentTarget(nullptr); | 164 m_event->setCurrentTarget(nullptr); |
| 165 TRACE_EVENT_INSTANT1(TRACE_DISABLED_BY_DEFAULT("devtools.timeline"), | |
| 166 "UpdateCounters", TRACE_EVENT_SCOPE_THREAD, "data", | |
| 167 InspectorUpdateCountersEvent::data()); | |
| 168 | 165 |
| 169 return EventTarget::dispatchEventResult(*m_event); | 166 return EventTarget::dispatchEventResult(*m_event); |
| 170 } | 167 } |
| 171 | 168 |
| 172 inline EventDispatchContinuation EventDispatcher::dispatchEventPreProcess( | 169 inline EventDispatchContinuation EventDispatcher::dispatchEventPreProcess( |
| 173 EventDispatchHandlingState*& preDispatchEventHandlerResult) { | 170 EventDispatchHandlingState*& preDispatchEventHandlerResult) { |
| 174 // Give the target node a chance to do some work before DOM event handlers get | 171 // Give the target node a chance to do some work before DOM event handlers get |
| 175 // a crack. | 172 // a crack. |
| 176 preDispatchEventHandlerResult = | 173 preDispatchEventHandlerResult = |
| 177 m_node->preDispatchEventHandler(m_event.get()); | 174 m_node->preDispatchEventHandler(m_event.get()); |
| (...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 307 // events to open select boxes. | 304 // events to open select boxes. |
| 308 if (!m_event->isTrusted() && m_event->isMouseEvent() && | 305 if (!m_event->isTrusted() && m_event->isMouseEvent() && |
| 309 m_event->type() == EventTypeNames::mousedown && | 306 m_event->type() == EventTypeNames::mousedown && |
| 310 isHTMLSelectElement(*m_node)) { | 307 isHTMLSelectElement(*m_node)) { |
| 311 UseCounter::count(m_node->document(), | 308 UseCounter::count(m_node->document(), |
| 312 UseCounter::UntrustedMouseDownEventDispatchedToSelect); | 309 UseCounter::UntrustedMouseDownEventDispatchedToSelect); |
| 313 } | 310 } |
| 314 } | 311 } |
| 315 | 312 |
| 316 } // namespace blink | 313 } // namespace blink |
| OLD | NEW |