Make sure that sticky items are processed in the right order.
We rely on positioning ancestors before descendants to get the right
position. This was very implicitly enforced before the regressing bug,
by reframing on position changes (due to the order
StickyScrollContainer::AddFrame was called, ancestors before children).
In order to support dynamic sticky changes without reframing, we need to
handle the case of an existing ancestor switching position to sticky
dynamically.
Luckily we already have the right data-structure for that, so the change
is rather trivial.
Write a testharness test for this because APZ does get the position
right, so it's more future-proof against regressions to just test the
raw layout values.
Differential Revision: https://phabricator.services.mozilla.com/D216858
bugzilla-url: https://bugzilla.mozilla.org/show_bug.cgi?id=1908242
gecko-commit: 67a9d7321ab6557156ae05bb1e7dd1261b757aa1
gecko-reviewers: TYLin