You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
And rename UpdateLayoutTree to RecalcStyle for usability.
This shouldn't have user-facing changes; it lays groundwork for
logic fixes.
Bug: 444481354
Change-Id: I2fcecaa318585f09d7bc0f4ef600dbd84295090d
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/6917594
Commit-Queue: Connor Clark <cjamcl@chromium.org>
Reviewed-by: Connor Clark <cjamcl@chromium.org>
Auto-Submit: Paul Irish <paulirish@chromium.org>
// Used to track paints so we track invalidations correctly per paint.
13
-
lethasPainted=false;
7
+
/**
8
+
* @file Associates invalidation to recalc/layout events; mostly used in "invalidation tracking" experiment.
9
+
* "Invalidations" == "mutations" == "damage".
10
+
* A DOM change that means we need to recompute style or layout is an invalidation that's tracked here.
11
+
* If the experiment `timeline-invalidation-tracking` is enabled, the `disabledByDefault('devtools.timeline.invalidationTracking')` trace category is enabled, which contains most of these events.
// If we have painted, then we can clear out the list of all existing
75
103
// invalidations, as we cannot associate them across frames.
76
-
allInvalidationTrackingEvents.length=0;
77
-
lastRecalcStyleEvent=null;
78
-
hasPainted=false;
104
+
thisFrame.pendingInvalidations.length=0;
105
+
thisFrame.lastRecalcStyleEvent=null;
106
+
thisFrame.hasPainted=false;
79
107
}
80
108
81
-
// Style invalidation events can occur before and during recalc styles. When we get a recalc style event (aka UpdateLayoutTree), we check and associate any prior invalidations with it.
82
-
// But any invalidations that occur during a UpdateLayoutTree
109
+
// Style invalidation events can occur before and during recalc styles. When we get a recalc style event, we check and associate any prior invalidations with it.
110
+
// But any invalidations that occur during a RecalcStyle
83
111
// event would be reported in trace events after. So each time we get an
84
112
// invalidation that might be due to a style recalc, we check if the
0 commit comments