Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 416e2026cb6c5117a75c93627cc0634a2634a38f
https://github.com/WebKit/WebKit/commit/416e2026cb6c5117a75c93627cc0634a2634a38f
Author: Simon Fraser <[email protected]>
Date: 2023-09-15 (Fri, 15 Sep 2023)
Changed paths:
M
LayoutTests/compositing/layer-creation/clipping-scope/nested-scroller-overlap-expected.txt
A
LayoutTests/compositing/shared-backing/overflow-scroll/absolute-in-nested-scroller-paint-order-expected.html
A
LayoutTests/compositing/shared-backing/overflow-scroll/absolute-in-nested-scroller-paint-order.html
A
LayoutTests/compositing/shared-backing/overflow-scroll/nested-scroller-sharing-expected.txt
A
LayoutTests/compositing/shared-backing/overflow-scroll/nested-scroller-sharing.html
A
LayoutTests/compositing/shared-backing/overflow-scroll/overlapping-scroller-sharing-expected.txt
A
LayoutTests/compositing/shared-backing/overflow-scroll/overlapping-scroller-sharing.html
M
LayoutTests/platform/ios-wk2/compositing/layer-creation/clipping-scope/nested-scroller-overlap-expected.txt
A
LayoutTests/platform/ios-wk2/compositing/shared-backing/overflow-scroll/nested-scroller-sharing-expected.txt
A
LayoutTests/platform/ios-wk2/compositing/shared-backing/overflow-scroll/overlapping-scroller-sharing-expected.txt
M Source/WebCore/rendering/RenderLayerCompositor.cpp
Log Message:
-----------
REGRESSION (265576@main): Wrong paint order of positioned and in-flow content
inside overflow:scroll
https://bugs.webkit.org/show_bug.cgi?id=261302
rdar://115144982
Reviewed by Antti Koivisto.
Backing sharing is used to reduce memory use by allowing multiple RenderLayers
(normally siblings)
which share the same stacking context ancestor to render into the same
compositing layer. This has
to be done in a way that preserves back-to-front paint order. The common case
where this kicks in is
a non-stacking context overflow:scroll with position:relative descendants.
265576@main added support for multiple backing sharing providers, but in a way
that broke certain
configurations, particularly with nested scrollers; the specific bug here was
that we computed that
the abspos "header" element could share backing with the parent scroller, but
that had it painting
behind the child scroller.
Getting backing sharing correct with overlapping and nested scrollers is hard,
so this patch limits
multiple backing sharing providers to non-overlapping overflow scrollers only
(which still fixes
walmart.com, the target of the original fix). A long comment was added to
explain the complexities
of these configurations.
Additional cleanup fixes: "continueBackingSharingSequence" is renamed to
"addBackingSharingCandidate", and "canUseMultipleProviders" to
"isAdditionalProviderCandidate". The
fix is to return false from "isAdditionalProviderCandidate" when things overlap.
*
LayoutTests/compositing/layer-creation/clipping-scope/nested-scroller-overlap-expected.txt:
*
LayoutTests/compositing/shared-backing/overflow-scroll/absolute-in-nested-scroller-paint-order-expected.html:
Added.
*
LayoutTests/compositing/shared-backing/overflow-scroll/absolute-in-nested-scroller-paint-order.html:
Added.
*
LayoutTests/compositing/shared-backing/overflow-scroll/nested-scroller-sharing-expected.txt:
Copied from
LayoutTests/platform/ios-wk2/compositing/layer-creation/clipping-scope/nested-scroller-overlap-expected.txt.
*
LayoutTests/compositing/shared-backing/overflow-scroll/nested-scroller-sharing.html:
Added.
*
LayoutTests/compositing/shared-backing/overflow-scroll/overlapping-scroller-sharing-expected.txt:
Added.
*
LayoutTests/compositing/shared-backing/overflow-scroll/overlapping-scroller-sharing.html:
Added.
*
LayoutTests/platform/ios-wk2/compositing/layer-creation/clipping-scope/nested-scroller-overlap-expected.txt:
*
LayoutTests/platform/ios-wk2/compositing/shared-backing/overflow-scroll/nested-scroller-sharing-expected.txt:
Added.
*
LayoutTests/platform/ios-wk2/compositing/shared-backing/overflow-scroll/overlapping-scroller-sharing-expected.txt:
Added.
* Source/WebCore/rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::BackingSharingState::firstProviderCandidateLayer
const):
(WebCore::RenderLayerCompositor::BackingSharingState::startBackingSharingSequence):
(WebCore::RenderLayerCompositor::BackingSharingState::addBackingSharingCandidate):
(WebCore::RenderLayerCompositor::BackingSharingState::endBackingSharingSequence):
(WebCore::RenderLayerCompositor::BackingSharingState::backingProviderCandidateForLayer):
(WebCore::RenderLayerCompositor::BackingSharingState::isAdditionalProviderCandidate
const):
(WebCore::RenderLayerCompositor::BackingSharingState::updateBeforeDescendantTraversal):
(WebCore::RenderLayerCompositor::BackingSharingState::updateAfterDescendantTraversal):
(WebCore::RenderLayerCompositor::computeCompositingRequirements):
(WebCore::RenderLayerCompositor::BackingSharingState::continueBackingSharingSequence):
Deleted.
(WebCore::RenderLayerCompositor::BackingSharingState::canUseMultipleProviders
const): Deleted.
Canonical link: https://commits.webkit.org/268028@main
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes