Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[@container] Clear skipped style recalc for all descendants
The existing code assumed we would always resume style recalc from the skipped container's layout, but that is not always the case. Take the following scenario which could happen with nested containers: 1. Style recalc is not skipped for an outer container because it is not marked for layout. 2. Style recalc is skipped for an inner container because it is marked for layout. 3. Layout changes the width of the outer container because the outer container is auto-sized, and changes size because an ancestor box changes its size. 4. The @container evaluation changes for the outer container, which means we enter UpdateStyleAndLayoutTreeForContainer() for the outer container. 5. We reach recalc for the inner container, whose subtree was skipped for style recalc, but we did not clear the skipping or retrieve the stored style recalc change. In this CL we always check, clear, and return the StyleRecalcChange if style recalc was skipped. Bug: 346264227 Change-Id: I3dc997850068a6751333ed588adf2f1f0e87518f Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5630638 Reviewed-by: Anders Hartvoll Ruud <[email protected]> Commit-Queue: Rune Lillesveen <[email protected]> Cr-Commit-Position: refs/heads/main@{#1317345}
- Loading branch information