OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
72 #include "core/page/ConsoleTypes.h" | 72 #include "core/page/ConsoleTypes.h" |
73 #include "core/page/DOMWindow.h" | 73 #include "core/page/DOMWindow.h" |
74 #include "core/rendering/RenderObject.h" | 74 #include "core/rendering/RenderObject.h" |
75 #include "core/workers/WorkerContext.h" | 75 #include "core/workers/WorkerContext.h" |
76 #include "core/workers/WorkerThread.h" | 76 #include "core/workers/WorkerThread.h" |
77 #include "core/xml/XMLHttpRequest.h" | 77 #include "core/xml/XMLHttpRequest.h" |
78 #include "modules/webdatabase/Database.h" | 78 #include "modules/webdatabase/Database.h" |
79 #include <wtf/StdLibExtras.h> | 79 #include <wtf/StdLibExtras.h> |
80 #include <wtf/text/CString.h> | 80 #include <wtf/text/CString.h> |
81 | 81 |
82 #include "core/platform/chromium/TraceEvent.h" | |
83 | |
84 namespace WebCore { | 82 namespace WebCore { |
85 | 83 |
86 static const char* const requestAnimationFrameEventName = "requestAnimationFrame
"; | 84 static const char* const requestAnimationFrameEventName = "requestAnimationFrame
"; |
87 static const char* const cancelAnimationFrameEventName = "cancelAnimationFrame"; | 85 static const char* const cancelAnimationFrameEventName = "cancelAnimationFrame"; |
88 static const char* const animationFrameFiredEventName = "animationFrameFired"; | 86 static const char* const animationFrameFiredEventName = "animationFrameFired"; |
89 static const char* const setTimerEventName = "setTimer"; | 87 static const char* const setTimerEventName = "setTimer"; |
90 static const char* const clearTimerEventName = "clearTimer"; | 88 static const char* const clearTimerEventName = "clearTimer"; |
91 static const char* const timerFiredEventName = "timerFired"; | 89 static const char* const timerFiredEventName = "timerFired"; |
92 | 90 |
93 namespace { | 91 namespace { |
(...skipping 385 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
479 } | 477 } |
480 | 478 |
481 void didDispatchXHRLoadEventImpl(const InspectorInstrumentationCookie& cookie) | 479 void didDispatchXHRLoadEventImpl(const InspectorInstrumentationCookie& cookie) |
482 { | 480 { |
483 if (InspectorTimelineAgent* timelineAgent = retrieveTimelineAgent(cookie)) | 481 if (InspectorTimelineAgent* timelineAgent = retrieveTimelineAgent(cookie)) |
484 timelineAgent->didDispatchXHRLoadEvent(); | 482 timelineAgent->didDispatchXHRLoadEvent(); |
485 } | 483 } |
486 | 484 |
487 void willPaintImpl(InstrumentingAgents* instrumentingAgents, RenderObject* rende
rer) | 485 void willPaintImpl(InstrumentingAgents* instrumentingAgents, RenderObject* rende
rer) |
488 { | 486 { |
489 TRACE_EVENT_INSTANT1("instrumentation", InstrumentationEvents::Paint, Instru
mentationEventArguments::PageId, reinterpret_cast<unsigned long long>(renderer->
frame()->page())); | |
490 | |
491 if (InspectorTimelineAgent* timelineAgent = instrumentingAgents->inspectorTi
melineAgent()) | 487 if (InspectorTimelineAgent* timelineAgent = instrumentingAgents->inspectorTi
melineAgent()) |
492 timelineAgent->willPaint(renderer->frame()); | 488 timelineAgent->willPaint(renderer); |
493 } | 489 } |
494 | 490 |
495 void didPaintImpl(InstrumentingAgents* instrumentingAgents, RenderObject* render
er, GraphicsContext* context, const LayoutRect& rect) | 491 void didPaintImpl(InstrumentingAgents* instrumentingAgents, RenderObject* render
er, GraphicsContext* context, const LayoutRect& rect) |
496 { | 492 { |
497 if (InspectorTimelineAgent* timelineAgent = instrumentingAgents->inspectorTi
melineAgent()) | 493 if (InspectorTimelineAgent* timelineAgent = instrumentingAgents->inspectorTi
melineAgent()) |
498 timelineAgent->didPaint(renderer, context, rect); | 494 timelineAgent->didPaint(renderer, context, rect); |
499 if (InspectorPageAgent* pageAgent = instrumentingAgents->inspectorPageAgent(
)) | 495 if (InspectorPageAgent* pageAgent = instrumentingAgents->inspectorPageAgent(
)) |
500 pageAgent->didPaint(renderer, context, rect); | 496 pageAgent->didPaint(renderer, context, rect); |
501 } | 497 } |
502 | 498 |
(...skipping 825 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1328 const char RasterTask[] = "RasterTask"; | 1324 const char RasterTask[] = "RasterTask"; |
1329 const char ImageDecodeTask[] = "ImageDecodeTask"; | 1325 const char ImageDecodeTask[] = "ImageDecodeTask"; |
1330 const char Paint[] = "Paint"; | 1326 const char Paint[] = "Paint"; |
1331 const char Layer[] = "Layer"; | 1327 const char Layer[] = "Layer"; |
1332 const char BeginFrame[] = "BeginFrame"; | 1328 const char BeginFrame[] = "BeginFrame"; |
1333 }; | 1329 }; |
1334 | 1330 |
1335 namespace InstrumentationEventArguments { | 1331 namespace InstrumentationEventArguments { |
1336 const char LayerId[] = "layerId"; | 1332 const char LayerId[] = "layerId"; |
1337 const char PageId[] = "pageId"; | 1333 const char PageId[] = "pageId"; |
| 1334 const char NodeId[] = "nodeId"; |
1338 }; | 1335 }; |
1339 | 1336 |
1340 } // namespace WebCore | 1337 } // namespace WebCore |
1341 | 1338 |
OLD | NEW |