https://bugs.webkit.org/show_bug.cgi?id=145032
rdar://problem/
20963679
Reviewed by Dean Jackson.
Source/WebCore:
After r183794 (or possibly an earlier commit), we failed to dynamically update
the configuration of layers that handled fixed background attachment on the root.
This would result in unpainted tiles, and non-fixed-background behavior.
Fix by calling RenderLayerCompositor::rootOrBodyStyleChanged() whenever the
style changes on the root or body renderers, and triggering a compositing update
if the fixedness of the background changes. It calls the existing rootBackgroundTransparencyChanged()
if the color changes.
Test: platform/mac-wk2/tiled-drawing/toggle-to-fixed-background.html
* rendering/RenderBox.cpp:
(WebCore::RenderBox::styleDidChange):
* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::rootOrBodyStyleChanged):
(WebCore::RenderLayerCompositor::rootBackgroundTransparencyChanged):
* rendering/RenderLayerCompositor.h:
LayoutTests:
Test that toggles the attachment of the body background to fixed, then dumps layers.
* platform/mac-wk2/tiled-drawing/toggle-to-fixed-background-expected.txt: Added.
* platform/mac-wk2/tiled-drawing/toggle-to-fixed-background.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@184371
268f45cc-cd09-0410-ab3c-
d52691b4dbfc