Changeset 149915 in webkit
- Timestamp:
- May 10, 2013 5:32:05 PM (11 years ago)
- Location:
- trunk
- Files:
-
- 4 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r149914 r149915 1 2013-05-10 Simon Fraser <simon.fraser@apple.com> 2 3 REGRESSION (r143626): Element shows as garbage in image gallery 4 https://bugs.webkit.org/show_bug.cgi?id=115946 5 6 Reviewed by Antti Koivisto. 7 8 Test that dumps layers for a visibility:hidden element with a child text node, 9 and with a visibility:visible child. The resulting compositing layer should 10 not be marked as opaque. 11 12 * compositing/contents-opaque/hidden-with-visible-child-expected.txt: Added. 13 * compositing/contents-opaque/hidden-with-visible-child.html: Added. 14 * compositing/contents-opaque/hidden-with-visible-text-expected.txt: Added. 15 * compositing/contents-opaque/hidden-with-visible-text.html: Added. 16 1 17 2013-05-10 Simon Fraser <simon.fraser@apple.com> 2 18 -
trunk/Source/WebCore/ChangeLog
r149914 r149915 1 2013-05-10 Simon Fraser <simon.fraser@apple.com> 2 3 REGRESSION (r143626): Element shows as garbage in image gallery 4 https://bugs.webkit.org/show_bug.cgi?id=115946 5 6 Reviewed by Antti Koivisto. 7 8 RenderLayer::backgroundIsKnownToBeOpaqueInRect() used hasVisibleContent() 9 to check whether the layer's content was hidden via the visibility property. 10 However, this assumed that a passing hasVisibleContent() check meant that the 11 entire area was covered by the renderers and layers checked layer. 12 13 This is not always true. It's possible to have a visibility:hidden layer 14 with a non-covering visbility:visible child, or even a single RenderText 15 child that happens to have visibility:visible style. In these situations, 16 hasVisibleContent() returns true but the entire area is not painted. 17 18 So we have to fall back to on a more conservative check using the 19 visibility style, which will give is a reliable answer for the current layer. 20 21 Tests: compositing/contents-opaque/hidden-with-visible-child.html 22 compositing/contents-opaque/hidden-with-visible-text.html 23 24 * rendering/RenderLayer.cpp: 25 (WebCore::RenderLayer::backgroundIsKnownToBeOpaqueInRect): 26 1 27 2013-05-10 Simon Fraser <simon.fraser@apple.com> 2 28 -
trunk/Source/WebCore/rendering/RenderLayer.cpp
r149914 r149915 5565 5565 return false; 5566 5566 5567 ASSERT(!m_visibleContentStatusDirty); 5568 if (!hasVisibleContent()) 5567 // We can't use hasVisibleContent(), because that will be true if our renderer is hidden, but some child 5568 // is visible and that child doesn't cover the entire rect. 5569 if (renderer()->style()->visibility() != VISIBLE) 5569 5570 return false; 5570 5571
Note: See TracChangeset
for help on using the changeset viewer.