| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef InspectorTraceEvents_h | 5 #ifndef InspectorTraceEvents_h |
| 6 #define InspectorTraceEvents_h | 6 #define InspectorTraceEvents_h |
| 7 | 7 |
| 8 #include "platform/EventTracer.h" | 8 #include "platform/EventTracer.h" |
| 9 #include "platform/TraceEvent.h" | 9 #include "platform/TraceEvent.h" |
| 10 #include "platform/heap/Handle.h" | |
| 11 #include "wtf/Forward.h" | 10 #include "wtf/Forward.h" |
| 12 #include "wtf/Functional.h" | |
| 13 | 11 |
| 14 namespace blink { | 12 namespace blink { |
| 15 | 13 |
| 16 class DescendantInvalidationSet; | |
| 17 class Document; | 14 class Document; |
| 18 class Element; | |
| 19 class Event; | 15 class Event; |
| 20 class ExecutionContext; | 16 class ExecutionContext; |
| 21 class FrameView; | 17 class FrameView; |
| 22 class GraphicsContext; | 18 class GraphicsContext; |
| 23 class GraphicsLayer; | 19 class GraphicsLayer; |
| 24 class KURL; | 20 class KURL; |
| 25 class LayoutRect; | 21 class LayoutRect; |
| 26 class LocalFrame; | 22 class LocalFrame; |
| 27 class Node; | 23 class Node; |
| 28 class RenderImage; | 24 class RenderImage; |
| 29 class RenderLayer; | 25 class RenderLayer; |
| 30 class RenderObject; | 26 class RenderObject; |
| 31 class ResourceRequest; | 27 class ResourceRequest; |
| 32 class ResourceResponse; | 28 class ResourceResponse; |
| 33 class ScriptCallStack; | 29 class ScriptCallStack; |
| 34 class ScriptSourceCode; | 30 class ScriptSourceCode; |
| 35 class StyleChangeReasonForTracing; | 31 class StyleChangeReasonForTracing; |
| 36 class TracedValue; | |
| 37 class WorkerThread; | 32 class WorkerThread; |
| 38 class XMLHttpRequest; | 33 class XMLHttpRequest; |
| 39 | 34 |
| 40 class InspectorLayoutEvent { | 35 class InspectorLayoutEvent { |
| 41 public: | 36 public: |
| 42 static PassRefPtr<TraceEvent::ConvertableToTraceFormat> beginData(FrameView*
); | 37 static PassRefPtr<TraceEvent::ConvertableToTraceFormat> beginData(FrameView*
); |
| 43 static PassRefPtr<TraceEvent::ConvertableToTraceFormat> endData(RenderObject
* rootForThisLayout); | 38 static PassRefPtr<TraceEvent::ConvertableToTraceFormat> endData(RenderObject
* rootForThisLayout); |
| 44 }; | 39 }; |
| 45 | 40 |
| 46 class InspectorStyleRecalcInvalidationTrackingEvent { | 41 class InspectorStyleRecalcInvalidationTrackingEvent { |
| 47 public: | 42 public: |
| 48 static PassRefPtr<TraceEvent::ConvertableToTraceFormat> data(Node*, const St
yleChangeReasonForTracing&); | 43 static PassRefPtr<TraceEvent::ConvertableToTraceFormat> data(Node*, const St
yleChangeReasonForTracing&); |
| 49 }; | 44 }; |
| 50 | 45 |
| 51 class InspectorStyleInvalidatorInvalidateEvent { | |
| 52 public: | |
| 53 static const char ElementHasPendingInvalidationList[]; | |
| 54 static const char InvalidateCustomPseudo[]; | |
| 55 static const char InvalidationSetMatchedAttribute[]; | |
| 56 static const char InvalidationSetMatchedClass[]; | |
| 57 static const char InvalidationSetMatchedId[]; | |
| 58 static const char InvalidationSetMatchedTagName[]; | |
| 59 static const char PreventStyleSharingForParent[]; | |
| 60 | |
| 61 static PassRefPtr<TraceEvent::ConvertableToTraceFormat> data(Element&, const
char* reason); | |
| 62 static PassRefPtr<TraceEvent::ConvertableToTraceFormat> selectorPart(Element
&, const char* reason, const String&); | |
| 63 static PassRefPtr<TraceEvent::ConvertableToTraceFormat> invalidationList(Ele
ment&, const WillBeHeapVector<RefPtrWillBeMember<DescendantInvalidationSet> >&); | |
| 64 | |
| 65 private: | |
| 66 static PassRefPtr<TracedValue> fillCommonPart(Element&, const char* reason); | |
| 67 }; | |
| 68 | |
| 69 #define TRACE_STYLE_INVALIDATOR_INVALIDATION(element, reason) \ | |
| 70 TRACE_EVENT_INSTANT1( \ | |
| 71 TRACE_DISABLED_BY_DEFAULT("devtools.timeline.invalidationTracking"), \ | |
| 72 "StyleInvalidatorInvalidationTracking", \ | |
| 73 "data", \ | |
| 74 InspectorStyleInvalidatorInvalidateEvent::data((element), (InspectorStyl
eInvalidatorInvalidateEvent::reason))) | |
| 75 | |
| 76 #define TRACE_STYLE_INVALIDATOR_INVALIDATION_SELECTORPART(element, reason, singl
eSelectorPart) \ | |
| 77 TRACE_EVENT_INSTANT1( \ | |
| 78 TRACE_DISABLED_BY_DEFAULT("devtools.timeline.invalidationTracking"), \ | |
| 79 "StyleInvalidatorInvalidationTracking", \ | |
| 80 "data", \ | |
| 81 InspectorStyleInvalidatorInvalidateEvent::selectorPart((element), (Inspe
ctorStyleInvalidatorInvalidateEvent::reason), (singleSelectorPart))) | |
| 82 | |
| 83 class InspectorLayoutInvalidationTrackingEvent { | 46 class InspectorLayoutInvalidationTrackingEvent { |
| 84 public: | 47 public: |
| 85 static PassRefPtr<TraceEvent::ConvertableToTraceFormat> data(const RenderObj
ect*); | 48 static PassRefPtr<TraceEvent::ConvertableToTraceFormat> data(const RenderObj
ect*); |
| 86 }; | 49 }; |
| 87 | 50 |
| 88 class InspectorPaintInvalidationTrackingEvent { | 51 class InspectorPaintInvalidationTrackingEvent { |
| 89 public: | 52 public: |
| 90 static PassRefPtr<TraceEvent::ConvertableToTraceFormat> data(const RenderObj
ect* renderer, const RenderObject* paintContainer); | 53 static PassRefPtr<TraceEvent::ConvertableToTraceFormat> data(const RenderObj
ect* renderer, const RenderObject* paintContainer); |
| 91 }; | 54 }; |
| 92 | 55 |
| (...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 225 | 188 |
| 226 class InspectorTracingSessionIdForWorkerEvent { | 189 class InspectorTracingSessionIdForWorkerEvent { |
| 227 public: | 190 public: |
| 228 static PassRefPtr<TraceEvent::ConvertableToTraceFormat> data(const String& s
essionId, WorkerThread*); | 191 static PassRefPtr<TraceEvent::ConvertableToTraceFormat> data(const String& s
essionId, WorkerThread*); |
| 229 }; | 192 }; |
| 230 | 193 |
| 231 } // namespace blink | 194 } // namespace blink |
| 232 | 195 |
| 233 | 196 |
| 234 #endif // !defined(InspectorTraceEvents_h) | 197 #endif // !defined(InspectorTraceEvents_h) |
| OLD | NEW |