Bug 1735872 [wpt PR 31250] - Find OOFs in the fragment tree when looking for a scroll...
commit14f83d5d781bd44c9d200205d8191b543e37ffde
authorMorten Stenshorne <mstensho@chromium.org>
Thu, 28 Oct 2021 10:23:22 +0000 (28 10:23 +0000)
committermoz-wptsync-bot <wptsync@mozilla.com>
Fri, 29 Oct 2021 10:24:24 +0000 (29 10:24 +0000)
treef2d67449e9d34cb4b728b180e6f2fd52aece8342
parent007e0db85f74a6b9b242b8c674d50cbe7b15fb31
Bug 1735872 [wpt PR 31250] - Find OOFs in the fragment tree when looking for a scroll anchor., a=testonly

Automatic update from web-platform-tests
Find OOFs in the fragment tree when looking for a scroll anchor.

The HasOutOfFlowFragmentChild() bits are taken from
https://chromium-review.googlesource.com/c/chromium/src/+/2640403 by
obrufau@igalia.com, and the changes in ScrollAnchor is a counterproposal
to how that CL solves it.

In LayoutNG block fragmentation, OOF fragments are normally placed as
direct children of the fragmentainers, so that's where we need to look
for them.

Additionally, in cases where we're not inside block fragmentation, look
for OOF child fragments inside the fragment(s) generated by the
candidate. This is in preparation for the CL mentioned above (which will
no longer populate LayoutBlock's PositionedObjects when LayoutNG is
used).

OOFs are easily missed in ScrollAnchor::Examine(), because OOFs don't
contribute to layout overflow, and this is why we needed this extra
effort in the first place (crbug.com/692701).

This fixes wpt/css/css-scroll-anchoring/abspos-in-multicol-001.html
when LayoutNGBlockFragmentation is enabled.

Bug: 829028
Test: external/wpt/css/css-scroll-anchoring/abspos-in-multicol-001.html
Change-Id: I25bd7b3a56b2405ec76823993eefed4889361250
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3195930
Reviewed-by: Steve Kobes <skobes@chromium.org>
Reviewed-by: Oriol Brufau <obrufau@igalia.com>
Commit-Queue: Morten Stenshorne <mstensho@chromium.org>
Cr-Commit-Position: refs/heads/main@{#933838}

--

wpt-commits: 39ef40f62d4f0ed55d2d9736140ec885ecce259e
wpt-pr: 31250
testing/web-platform/tests/css/css-scroll-anchoring/abspos-in-multicol-003.html [new file with mode: 0644]