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

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

Issue 239303003: Add devtools trace event for event dispatching (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 8 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/events/EventDispatcher.cpp
diff --git a/Source/core/events/EventDispatcher.cpp b/Source/core/events/EventDispatcher.cpp
index c4485eff66f80cd94cc96649f537921a2e70813a..8f505b55d002f29948fbfbf079110994850b1b7f 100644
--- a/Source/core/events/EventDispatcher.cpp
+++ b/Source/core/events/EventDispatcher.cpp
@@ -33,6 +33,7 @@
#include "core/events/WindowEventContext.h"
#include "core/frame/FrameView.h"
#include "core/inspector/InspectorInstrumentation.h"
+#include "platform/TraceEvent.h"
#include "wtf/RefPtr.h"
namespace WebCore {
@@ -112,6 +113,8 @@ bool EventDispatcher::dispatch()
ASSERT(!NoEventDispatchAssertion::isEventDispatchForbidden());
ASSERT(m_event->target());
WindowEventContext windowEventContext(m_event.get(), m_node.get(), topNodeEventContext());
+ TRACE_EVENT1(TRACE_DISABLED_BY_DEFAULT("devtools-timeline"), "EventDispatcher::dispatch", "type", m_event->type().ascii());
+ // FIXME(361045): remove InspectorInstrumentation calls once DevTools Timeline migrates to tracing.
InspectorInstrumentationCookie cookie = InspectorInstrumentation::willDispatchEvent(&m_node->document(), *m_event, windowEventContext.window(), m_node.get(), m_event->eventPath());
void* preDispatchEventHandlerResult;
« no previous file with comments | « LayoutTests/inspector-protocol/timeline/timeline-dispatchEvent-expected.txt ('k') | Source/core/frame/DOMWindow.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698