From 4a348b278d25edc4a98642410673b35364c8ec39 Mon Sep 17 00:00:00 2001 From: Xianzhu Wang Date: Fri, 13 Dec 2024 20:19:23 -0800 Subject: [PATCH] [RasterInducingScroll] Force update even without raster invalidation The following changes won't cause raster invalidation: - A scroller is added/removed without any visible change; - Some scrolling content out of a non-composited scroller's scrollport changes. Previously we skipped cc layer update because nothing visible changed. However, future raster-inducing scroll without main-thread update could scroll the out-of-date content into view. Now force update in RasterInducingScroll in ContentLayerClientImpl::UpdateCcLayer(). Bug: 364669904 Change-Id: I636d3f92a2a98db50f30160c2e214735311d6769 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6090759 Reviewed-by: Philip Rogers Commit-Queue: Xianzhu Wang Cr-Commit-Position: refs/heads/main@{#1396313} --- ...croller-then-scroll-content-into-view.html | 22 +++++++++++++++++++ .../content-change-then-scroll-into-view.html | 22 +++++++++++++++++++ 2 files changed, 44 insertions(+) create mode 100644 css/css-overflow/add-scroller-then-scroll-content-into-view.html create mode 100644 css/css-overflow/content-change-then-scroll-into-view.html diff --git a/css/css-overflow/add-scroller-then-scroll-content-into-view.html b/css/css-overflow/add-scroller-then-scroll-content-into-view.html new file mode 100644 index 00000000000000..bbe4ec33c942d7 --- /dev/null +++ b/css/css-overflow/add-scroller-then-scroll-content-into-view.html @@ -0,0 +1,22 @@ + + + + + + +

Test passes if there is a filled green square and no red.

+ + diff --git a/css/css-overflow/content-change-then-scroll-into-view.html b/css/css-overflow/content-change-then-scroll-into-view.html new file mode 100644 index 00000000000000..ec8836d5cb9558 --- /dev/null +++ b/css/css-overflow/content-change-then-scroll-into-view.html @@ -0,0 +1,22 @@ + + + + + + +

Test passes if there is a filled green square and no red.

+
+
+
+
+