Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 5885f16b5d2d0c379977942d53870104406e488f
      
https://github.com/WebKit/WebKit/commit/5885f16b5d2d0c379977942d53870104406e488f
  Author: Simon Fraser <[email protected]>
  Date:   2026-05-28 (Thu, 28 May 2026)

  Changed paths:
    M 
LayoutTests/css3/blending/repaint/blend-mode-isolate-stacking-context-expected.txt
    A 
LayoutTests/fast/repaint/repaint-on-layer-creation-from-transition-expected.txt
    A LayoutTests/fast/repaint/repaint-on-layer-creation-from-transition.html
    M 
LayoutTests/platform/ios/css3/blending/repaint/blend-mode-isolate-stacking-context-expected.txt
    M Source/WebCore/rendering/RenderElement.cpp
    M Source/WebCore/rendering/RenderLayerBacking.cpp
    M Source/WebCore/rendering/RenderLayerCompositor.cpp

  Log Message:
  -----------
  Dots for photo galleries on lemonde.fr repaint incorrectly with zoom
https://bugs.webkit.org/show_bug.cgi?id=315370
rdar://176665892

Reviewed by Alan Baradlay.

The content in question triggered an opacity animation from opacity 1, with a 
simultaneous
size change, so the renderer changed from having no RenderLayer to having a 
layer by
virtue of an opacity transition.

The "gaining a layer" repaint branch in 
`RenderElement::repaintBeforeStyleChange()`
failed to do a repaint in this case, because it didn't take into account the 
fact
that animated opacity will create a layer. Fix by simply checking for non-auto
used z-index, because StyleAdjuster has already set this based on all the 
properties
that might create layers, including filters, backdrop-filter and animations.

Zoom isn't specifically a requirement for the bug, but triggered it in some 
scenarios;
likewise with the border-radius that's needed in the test case. I also verified 
that
the fix also works when compositing for opacity animations is disabled.

Test: fast/repaint/repaint-on-layer-creation-from-transition.html

* 
LayoutTests/css3/blending/repaint/blend-mode-isolate-stacking-context-expected.txt:
* 
LayoutTests/fast/repaint/repaint-on-layer-creation-from-transition-expected.txt:
 Added.
* LayoutTests/fast/repaint/repaint-on-layer-creation-from-transition.html: 
Added.
* 
LayoutTests/platform/ios/css3/blending/repaint/blend-mode-isolate-stacking-context-expected.txt:
* Source/WebCore/rendering/RenderElement.cpp:
(WebCore::RenderElement::repaintBeforeStyleChange):
* Source/WebCore/rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::setContentsNeedDisplayInRect): Just whitespace
* Source/WebCore/rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::requiresCompositingForAnimation const): Just 
formatting

Canonical link: https://commits.webkit.org/314039@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to