REGRESSION (r238090) Composited iframes that resize from zero don't show
authorsimon.fraser@apple.com <simon.fraser@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 16 Nov 2018 05:29:45 +0000 (05:29 +0000)
committersimon.fraser@apple.com <simon.fraser@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 16 Nov 2018 05:29:45 +0000 (05:29 +0000)
commitb14600fd3944939957e4476d5f46f8236fc0fb75
tree5fbe4ac7029da0e5f8889db2eedfd58ee6b7224e
parentf4ed01071da0f6e8c2419eb0d598a5eb42b7d7b0
REGRESSION (r238090) Composited iframes that resize from zero don't show
https://bugs.webkit.org/show_bug.cgi?id=191733
rdar://problem/46107764

Reviewed by Zalan Bujtas.
Source/WebCore:

A zero-sized iframe whose contents are composited should not trigger compositing in the
parent document (see code in requiresCompositingForFrame()), but when the <iframe> element
was resized without a style change (e.g. because it's width: 100%, height: 100% and the
parent resizes), there was no code that triggered a compositing update.

Fix by having RenderLayer::updateLayerPosition() trigger an update when the size changes,
for a RenderWidget whose contents are composited.

Test: compositing/iframes/resize-from-zero-size.html

* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::updateLayerPosition):

LayoutTests:

* compositing/iframes/resize-from-zero-size-expected.txt: Added.
* compositing/iframes/resize-from-zero-size.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@238269 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/compositing/iframes/resize-from-zero-size-expected.txt [new file with mode: 0644]
LayoutTests/compositing/iframes/resize-from-zero-size.html [new file with mode: 0644]
Source/WebCore/ChangeLog
Source/WebCore/rendering/RenderLayer.cpp