Title: [294292] branches/safari-613-branch
- Revision
- 294292
- Author
- alanc...@apple.com
- Date
- 2022-05-16 23:10:19 -0700 (Mon, 16 May 2022)
Log Message
Cherry-pick r292350. rdar://problem/90589355
intersectsWithAncestor should take fragmented boxes into account.
https://bugs.webkit.org/show_bug.cgi?id=238648
Reviewed by Dean Jackson.
Source/WebCore:
Test: compositing/backing/backing-store-columns-inside-position-fixed.html
* rendering/RenderLayerBacking.cpp:
(WebCore::intersectsWithAncestor):
Use boundingBox() for intersectsWithAncestor, so that we can explicitly request the box that contains
all fragment boxes.
LayoutTests:
* compositing/backing/backing-store-columns-inside-position-fixed-expected.txt: Added.
* compositing/backing/backing-store-columns-inside-position-fixed.html: Added.
Adds new test that scrolls content split into columns until the first column is offscreen, to confirm
that we still have a backing store.
Canonical link: https://commits.webkit.org/249215@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@292350 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Modified Paths
Added Paths
Diff
Modified: branches/safari-613-branch/LayoutTests/ChangeLog (294291 => 294292)
--- branches/safari-613-branch/LayoutTests/ChangeLog 2022-05-17 05:59:55 UTC (rev 294291)
+++ branches/safari-613-branch/LayoutTests/ChangeLog 2022-05-17 06:10:19 UTC (rev 294292)
@@ -1,3 +1,46 @@
+2022-05-16 Alan Coon <alanc...@apple.com>
+
+ Cherry-pick r292350. rdar://problem/90589355
+
+ intersectsWithAncestor should take fragmented boxes into account.
+ https://bugs.webkit.org/show_bug.cgi?id=238648
+
+ Reviewed by Dean Jackson.
+
+ Source/WebCore:
+
+ Test: compositing/backing/backing-store-columns-inside-position-fixed.html
+
+ * rendering/RenderLayerBacking.cpp:
+ (WebCore::intersectsWithAncestor):
+
+ Use boundingBox() for intersectsWithAncestor, so that we can explicitly request the box that contains
+ all fragment boxes.
+
+ LayoutTests:
+
+ * compositing/backing/backing-store-columns-inside-position-fixed-expected.txt: Added.
+ * compositing/backing/backing-store-columns-inside-position-fixed.html: Added.
+
+ Adds new test that scrolls content split into columns until the first column is offscreen, to confirm
+ that we still have a backing store.
+
+ Canonical link: https://commits.webkit.org/249215@main
+ git-svn-id: https://svn.webkit.org/repository/webkit/trunk@292350 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+ 2022-04-04 Matt Woodrow <mattwood...@apple.com>
+
+ intersectsWithAncestor should take fragmented boxes into account.
+ https://bugs.webkit.org/show_bug.cgi?id=238648
+
+ Reviewed by Dean Jackson.
+
+ * compositing/backing/backing-store-columns-inside-position-fixed-expected.txt: Added.
+ * compositing/backing/backing-store-columns-inside-position-fixed.html: Added.
+
+ Adds new test that scrolls content split into columns until the first column is offscreen, to confirm
+ that we still have a backing store.
+
2022-05-03 Sihui Liu <sihui_...@apple.com>
StorageMap::removeItem may fail to remove item from map
Added: branches/safari-613-branch/LayoutTests/compositing/backing/backing-store-columns-inside-position-fixed-expected.txt (0 => 294292)
--- branches/safari-613-branch/LayoutTests/compositing/backing/backing-store-columns-inside-position-fixed-expected.txt (rev 0)
+++ branches/safari-613-branch/LayoutTests/compositing/backing/backing-store-columns-inside-position-fixed-expected.txt 2022-05-17 06:10:19 UTC (rev 294292)
@@ -0,0 +1,21 @@
+(GraphicsLayer
+ (anchor 0.00 0.00)
+ (bounds 800.00 600.00)
+ (backingStoreAttached 1)
+ (children 1
+ (GraphicsLayer
+ (bounds 800.00 600.00)
+ (contentsOpaque 1)
+ (backingStoreAttached 1)
+ (children 1
+ (GraphicsLayer
+ (position 8.00 0.00)
+ (bounds 600.00 600.00)
+ (drawsContent 1)
+ (backingStoreAttached 1)
+ )
+ )
+ )
+ )
+)
+
Added: branches/safari-613-branch/LayoutTests/compositing/backing/backing-store-columns-inside-position-fixed.html (0 => 294292)
--- branches/safari-613-branch/LayoutTests/compositing/backing/backing-store-columns-inside-position-fixed.html (rev 0)
+++ branches/safari-613-branch/LayoutTests/compositing/backing/backing-store-columns-inside-position-fixed.html 2022-05-17 06:10:19 UTC (rev 294292)
@@ -0,0 +1,71 @@
+<!DOCTYPE html>
+<html>
+<head>
+<style>
+#out {
+ position: absolute;
+}
+
+.fixed {
+ position: fixed;
+ top: 0px;
+ bottom:0px;
+ overflow-x: scroll;
+}
+.scrolled {
+ column-width: 200px;
+ column-fill: auto;
+ height: 200px;
+ width: 600px;
+}
+.filler {
+ width: 200px;
+ height: 200px;
+ background-color:blue;
+}
+</style>
+<script>
+if (window.testRunner) {
+ testRunner.dumpAsText();
+ testRunner.waitUntilDone();
+}
+
+window._onload_ = function() {
+ if (!window.testRunner)
+ return;
+
+ requestAnimationFrame(() => {
+
+ let scroller = document.getElementById('fixed');
+ scroller.scrollTo(400, 0);
+
+ let uiScript = `(function() {
+ uiController.doAfterNextStablePresentationUpdate(function() {
+ uiController.uiScriptComplete();
+ });
+ })()`
+
+ testRunner.runUIScript(uiScript, () => {
+ let afterLayers = internals.layerTreeAsText(document, internals.LAYER_TREE_INCLUDES_BACKING_STORE_ATTACHED);
+ let out = document.getElementById('out');
+ out.textContent = `${afterLayers}`
+ testRunner.notifyDone();
+ });
+ });
+};
+</script>
+</head>
+<body>
+<pre id="out"></pre>
+
+<div id="fixed" class="fixed">
+ <div class="scrolled">
+ <div class="filler"></div>
+ <div class="filler"></div>
+ <div class="filler"></div>
+ <div class="filler"></div>
+ <div class="filler"></div>
+ </div>
+</div>
+</body>
+</html>
Modified: branches/safari-613-branch/Source/WebCore/ChangeLog (294291 => 294292)
--- branches/safari-613-branch/Source/WebCore/ChangeLog 2022-05-17 05:59:55 UTC (rev 294291)
+++ branches/safari-613-branch/Source/WebCore/ChangeLog 2022-05-17 06:10:19 UTC (rev 294292)
@@ -1,5 +1,50 @@
2022-05-16 Alan Coon <alanc...@apple.com>
+ Cherry-pick r292350. rdar://problem/90589355
+
+ intersectsWithAncestor should take fragmented boxes into account.
+ https://bugs.webkit.org/show_bug.cgi?id=238648
+
+ Reviewed by Dean Jackson.
+
+ Source/WebCore:
+
+ Test: compositing/backing/backing-store-columns-inside-position-fixed.html
+
+ * rendering/RenderLayerBacking.cpp:
+ (WebCore::intersectsWithAncestor):
+
+ Use boundingBox() for intersectsWithAncestor, so that we can explicitly request the box that contains
+ all fragment boxes.
+
+ LayoutTests:
+
+ * compositing/backing/backing-store-columns-inside-position-fixed-expected.txt: Added.
+ * compositing/backing/backing-store-columns-inside-position-fixed.html: Added.
+
+ Adds new test that scrolls content split into columns until the first column is offscreen, to confirm
+ that we still have a backing store.
+
+ Canonical link: https://commits.webkit.org/249215@main
+ git-svn-id: https://svn.webkit.org/repository/webkit/trunk@292350 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+ 2022-04-04 Matt Woodrow <mattwood...@apple.com>
+
+ intersectsWithAncestor should take fragmented boxes into account.
+ https://bugs.webkit.org/show_bug.cgi?id=238648
+
+ Reviewed by Dean Jackson.
+
+ Test: compositing/backing/backing-store-columns-inside-position-fixed.html
+
+ * rendering/RenderLayerBacking.cpp:
+ (WebCore::intersectsWithAncestor):
+
+ Use boundingBox() for intersectsWithAncestor, so that we can explicitly request the box that contains
+ all fragment boxes.
+
+2022-05-16 Alan Coon <alanc...@apple.com>
+
Apply patch. rdar://problem/88672183
2022-02-19 Antoine Quint <grao...@webkit.org>
Modified: branches/safari-613-branch/Source/WebCore/rendering/RenderLayerBacking.cpp (294291 => 294292)
--- branches/safari-613-branch/Source/WebCore/rendering/RenderLayerBacking.cpp 2022-05-17 05:59:55 UTC (rev 294291)
+++ branches/safari-613-branch/Source/WebCore/rendering/RenderLayerBacking.cpp 2022-05-17 06:10:19 UTC (rev 294292)
@@ -2799,9 +2799,7 @@
return std::nullopt;
}
- auto offset = child.convertToLayerCoords(&ancestor, { }, RenderLayer::AdjustForColumns);
- auto overlap = child.overlapBounds();
- overlap.moveBy(offset);
+ auto overlap = child.boundingBox(&ancestor, child.offsetFromAncestor(&ancestor), RenderLayer::UseFragmentBoxesExcludingCompositing);
return overlap.intersects(ancestorCompositedBounds);
}
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes