| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2009, 2010, 2011 Apple Inc. All rights reserved. | 2 * Copyright (C) 2009, 2010, 2011 Apple Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 306 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 317 bool hasAncestorClippingLayer = compositor()->clippedByAncestor(m_owningLaye
r); | 317 bool hasAncestorClippingLayer = compositor()->clippedByAncestor(m_owningLaye
r); |
| 318 bool clippingAncestorIsScrollParent = m_owningLayer->renderer()->containingB
lock()->enclosingLayer() == m_owningLayer->ancestorScrollingLayer(); | 318 bool clippingAncestorIsScrollParent = m_owningLayer->renderer()->containingB
lock()->enclosingLayer() == m_owningLayer->ancestorScrollingLayer(); |
| 319 if (hasAncestorClippingLayer && clippingAncestorIsScrollParent) | 319 if (hasAncestorClippingLayer && clippingAncestorIsScrollParent) |
| 320 return false; | 320 return false; |
| 321 | 321 |
| 322 return true; | 322 return true; |
| 323 } | 323 } |
| 324 | 324 |
| 325 void CompositedLayerMapping::updateCompositedBounds() | 325 void CompositedLayerMapping::updateCompositedBounds() |
| 326 { | 326 { |
| 327 // We need to know if we draw content in order to update our bounds (this ha
s an effect |
| 328 // on whether or not descendands will paint into our backing). Update this v
alue now. |
| 329 updateDrawsContent(isSimpleContainerCompositingLayer()); |
| 330 |
| 327 IntRect layerBounds = compositor()->calculateCompositedBounds(m_owningLayer,
m_owningLayer); | 331 IntRect layerBounds = compositor()->calculateCompositedBounds(m_owningLayer,
m_owningLayer); |
| 328 | 332 |
| 329 // Clip to the size of the document or enclosing overflow-scroll layer. | 333 // Clip to the size of the document or enclosing overflow-scroll layer. |
| 330 // If this or an ancestor is transformed, we can't currently compute the cor
rect rect to intersect with. | 334 // If this or an ancestor is transformed, we can't currently compute the cor
rect rect to intersect with. |
| 331 // We'd need RenderObject::convertContainerToLocalQuad(), which doesn't yet
exist. | 335 // We'd need RenderObject::convertContainerToLocalQuad(), which doesn't yet
exist. |
| 332 if (shouldClipCompositedBounds()) { | 336 if (shouldClipCompositedBounds()) { |
| 333 RenderView* view = m_owningLayer->renderer()->view(); | 337 RenderView* view = m_owningLayer->renderer()->view(); |
| 334 RenderLayer* rootLayer = view->layer(); | 338 RenderLayer* rootLayer = view->layer(); |
| 335 | 339 |
| 336 LayoutRect clippingBounds; | 340 LayoutRect clippingBounds; |
| (...skipping 1665 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2002 } else if (graphicsLayer == m_scrollingContentsLayer.get()) { | 2006 } else if (graphicsLayer == m_scrollingContentsLayer.get()) { |
| 2003 name = "Scrolling Contents Layer"; | 2007 name = "Scrolling Contents Layer"; |
| 2004 } else { | 2008 } else { |
| 2005 ASSERT_NOT_REACHED(); | 2009 ASSERT_NOT_REACHED(); |
| 2006 } | 2010 } |
| 2007 | 2011 |
| 2008 return name; | 2012 return name; |
| 2009 } | 2013 } |
| 2010 | 2014 |
| 2011 } // namespace WebCore | 2015 } // namespace WebCore |
| OLD | NEW |