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

Unified Diff: Source/core/inspector/InspectorTraceEvents.h

Issue 1025213002: Begin tracking why layout is invalidated (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 9 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/inspector/InspectorTraceEvents.h
diff --git a/Source/core/inspector/InspectorTraceEvents.h b/Source/core/inspector/InspectorTraceEvents.h
index 3468e7c6a57a77f55ba2df06f635f983ffbf351a..4c60cc2d6904ec3644ce6291adbfe0165888b531 100644
--- a/Source/core/inspector/InspectorTraceEvents.h
+++ b/Source/core/inspector/InspectorTraceEvents.h
@@ -108,9 +108,39 @@ private:
"data", \
InspectorStyleInvalidatorInvalidateEvent::selectorPart((element), (InspectorStyleInvalidatorInvalidateEvent::reason), (invalidationSet), (singleSelectorPart)))
+// From a web developer's perspective: what caused this layout? This is strictly
+// for tracing. Blink logic must not depend on these.
+namespace LayoutInvalidationReason {
+extern const char Unknown[];
+extern const char SizeChanged[];
+extern const char AncestorMoved[];
+extern const char StyleChange[];
+extern const char DomChanged[];
+extern const char TextChanged[];
+extern const char PrintingChanged[];
+extern const char AttributeChanged[];
+extern const char ColumnsChanged[];
+extern const char ChildAnonymousBlockChanged[];
+extern const char AnonymousBlockChange[];
+extern const char Fullscreen[];
+extern const char ChildChanged[];
+extern const char ListValueChange[];
+extern const char ImageChanged[];
+extern const char LineBoxesChanged[];
+extern const char SliderValueChanged[];
+extern const char AncestorMarginCollapsing[];
+extern const char FieldsetChanged[];
+extern const char TextAutosizing[];
+extern const char SvgResourceInvalidated[];
+}
+
+// LayoutInvalidationReasonForTracing is strictly for tracing. Blink logic must
+// not depend on this value.
+typedef const char LayoutInvalidationReasonForTracing[];
+
class InspectorLayoutInvalidationTrackingEvent {
public:
- static PassRefPtr<TraceEvent::ConvertableToTraceFormat> data(const LayoutObject*);
+ static PassRefPtr<TraceEvent::ConvertableToTraceFormat> data(const LayoutObject*, LayoutInvalidationReasonForTracing);
};
class InspectorPaintInvalidationTrackingEvent {

Powered by Google App Engine
This is Rietveld 408576698