| Index: Source/core/rendering/compositing/RenderLayerCompositor.cpp
|
| diff --git a/Source/core/rendering/compositing/RenderLayerCompositor.cpp b/Source/core/rendering/compositing/RenderLayerCompositor.cpp
|
| index 1ec3750969ebc2b8613ca5c6ebce60d59bc70495..60f14a8d97add7bdb701bdb869aa38682a22d067 100644
|
| --- a/Source/core/rendering/compositing/RenderLayerCompositor.cpp
|
| +++ b/Source/core/rendering/compositing/RenderLayerCompositor.cpp
|
| @@ -727,7 +727,14 @@ bool RenderLayerCompositor::updateLayerIfViewportConstrained(RenderLayer* layer)
|
| bool RenderLayerCompositor::canSquashIntoCurrentSquashingOwner(const RenderLayer* layer, const RenderLayerCompositor::SquashingState& squashingState, const RenderLayer* clippingAncestor)
|
| {
|
| ASSERT(clippingAncestor);
|
| - return clippingAncestor == squashingState.clippingAncestorForMostRecentMapping;
|
| + if (clippingAncestor != squashingState.clippingAncestorForMostRecentMapping)
|
| + return false;
|
| +
|
| + ASSERT(squashingState.hasMostRecentMapping);
|
| + if (layer->scrollsWithRespectTo(&squashingState.mostRecentMapping->owningLayer()))
|
| + return false;
|
| +
|
| + return true;
|
| }
|
|
|
| RenderLayerCompositor::CompositingStateTransitionType RenderLayerCompositor::computeCompositedLayerUpdate(RenderLayer* layer)
|
| @@ -947,15 +954,6 @@ void RenderLayerCompositor::computeCompositingRequirements(RenderLayer* ancestor
|
|
|
| reasonsToComposite |= overlapCompositingReason;
|
|
|
| - // If the layer is squashable, but would scroll differently than the
|
| - // most recent backing that it would squash onto, then don't squash it.
|
| - // Note that this happens before we know all possible compositing reasons
|
| - // for this layer, but it's OK because we're just forcing the layer conservatively
|
| - // to be separately composited rather than squashed, anyway.
|
| - if (currentRecursionData.m_mostRecentCompositedLayer && requiresSquashing(reasonsToComposite)
|
| - && layer->scrollsWithRespectTo(currentRecursionData.m_mostRecentCompositedLayer))
|
| - reasonsToComposite |= CompositingReasonOverlapsWithoutSquashingTarget;
|
| -
|
| // The children of this layer don't need to composite, unless there is
|
| // a compositing layer among them, so start by inheriting the compositing
|
| // ancestor with m_subtreeIsCompositing set to false.
|
| @@ -1179,7 +1177,7 @@ void RenderLayerCompositor::assignLayersToBackingsInternal(RenderLayer* layer, S
|
| clippingAncestor = layer;
|
|
|
| if (layerSquashingEnabled() && requiresSquashing(layer->compositingReasons()) && !canSquashIntoCurrentSquashingOwner(layer, squashingState, clippingAncestor))
|
| - layer->setCompositingReasons(layer->compositingReasons() | CompositingReasonOverlapsWithoutSquashingTarget);
|
| + layer->setCompositingReasons(layer->compositingReasons() | CompositingReasonNoSquashingTargetFound);
|
|
|
| CompositingStateTransitionType compositedLayerUpdate = computeCompositedLayerUpdate(layer);
|
|
|
|
|