Changeset 137248 in webkit
- Timestamp:
- Dec 10, 2012, 9:54:06 PM (13 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r137244 r137248 1 2012-12-10 Simon Fraser <simon.fraser@apple.com> 2 3 REGRESSION(r137215): WebKit stretches and shrinks a part of screen on scroll 4 https://bugs.webkit.org/show_bug.cgi?id=104626 5 6 Reviewed by Beth Dakin. 7 8 Testcase that scrolls an overflow area containing a compositing layer. 9 10 * compositing/repaint/clipped-layer-size-change-expected.html: Added. 11 * compositing/repaint/clipped-layer-size-change.html: Added. 12 1 13 2012-12-10 Noel Gordon <noel.gordon@gmail.com> 2 14 -
trunk/Source/WebCore/ChangeLog
r137245 r137248 1 2012-12-10 Simon Fraser <simon.fraser@apple.com> 2 3 REGRESSION (r137215): WebKit stretches and shrinks a part of screen on scroll 4 https://bugs.webkit.org/show_bug.cgi?id=104626 5 6 Reviewed by Beth Dakin. 7 8 r137215 removed a compositing layer repaint on size changes. However, there 9 are cases where the compositing code constrains layer size by clipping 10 with the viewport and a clipping ancestor. When that happens, we must 11 invalidate the layer on a size change to avoid showing stretched or 12 shrunken content. 13 14 Test: compositing/repaint/clipped-layer-size-change.html 15 16 * rendering/RenderLayerBacking.cpp: 17 (WebCore::RenderLayerBacking::RenderLayerBacking): 18 (WebCore::RenderLayerBacking::updateCompositedBounds): 19 (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry): 20 * rendering/RenderLayerBacking.h: 21 (RenderLayerBacking): 22 1 23 2012-12-10 Dean Jackson <dino@apple.com> 2 24 -
trunk/Source/WebCore/rendering/RenderLayerBacking.cpp
r137215 r137248 102 102 , m_scrollLayerID(0) 103 103 , m_artificiallyInflatedBounds(false) 104 , m_boundsConstrainedByClipping(false) 104 105 , m_isMainFrameRenderViewLayer(false) 105 106 , m_usingTiledCacheLayer(false) … … 367 368 } 368 369 369 370 370 void RenderLayerBacking::updateCompositedBounds() 371 371 { … … 390 390 391 391 layerBounds.intersect(pixelSnappedIntRect(clippingBounds)); 392 } 392 m_boundsConstrainedByClipping = true; 393 } else 394 m_boundsConstrainedByClipping = false; 393 395 394 396 // If the element has a transform-origin that has fixed lengths, and the renderer has zero size, … … 632 634 FloatSize oldSize = m_graphicsLayer->size(); 633 635 FloatSize newSize = relativeCompositingBounds.size(); 634 if (oldSize != newSize) 636 if (oldSize != newSize) { 635 637 m_graphicsLayer->setSize(newSize); 638 // Usually invalidation will happen via layout etc, but if we've affected the layer 639 // size by constraining relative to a clipping ancestor or the viewport, we 640 // have to invalidate to avoid showing stretched content. 641 if (m_boundsConstrainedByClipping) 642 m_graphicsLayer->setNeedsDisplay(); 643 } 636 644 637 645 // If we have a layer that clips children, position it. -
trunk/Source/WebCore/rendering/RenderLayerBacking.h
r137108 r137248 276 276 IntRect m_compositedBounds; 277 277 278 bool m_artificiallyInflatedBounds; // bounds had to be made non-zero to make transform-origin work 278 bool m_artificiallyInflatedBounds; // bounds had to be made non-zero to make transform-origin work 279 bool m_boundsConstrainedByClipping; 279 280 bool m_isMainFrameRenderViewLayer; 280 281 bool m_usingTiledCacheLayer;
Note:
See TracChangeset
for help on using the changeset viewer.