Index: Source/core/layout/compositing/DeprecatedPaintLayerCompositor.cpp |
diff --git a/Source/core/layout/compositing/DeprecatedPaintLayerCompositor.cpp b/Source/core/layout/compositing/DeprecatedPaintLayerCompositor.cpp |
index 7f50b0f64c6a861ba8f197f6b2e85458a96d4793..ceb603cce62252f8ff3d4dc22317b940d83016ab 100644 |
--- a/Source/core/layout/compositing/DeprecatedPaintLayerCompositor.cpp |
+++ b/Source/core/layout/compositing/DeprecatedPaintLayerCompositor.cpp |
@@ -194,6 +194,10 @@ void updateDescendantDependentFlagsForEntireSubtree(DeprecatedPaintLayer& layer) |
void DeprecatedPaintLayerCompositor::updateIfNeededRecursive() |
{ |
+ FrameView* view = m_layoutView.frameView(); |
+ if (view->shouldThrottleStyleLayoutAndCompositingUpdates()) |
+ return; |
+ |
for (Frame* child = m_layoutView.frameView()->frame().tree().firstChild(); child; child = child->tree().nextSibling()) { |
if (!child->isLocalFrame()) |
continue; |
@@ -238,8 +242,12 @@ void DeprecatedPaintLayerCompositor::updateIfNeededRecursive() |
ASSERT(lifecycle().state() == DocumentLifecycle::CompositingClean); |
assertNoUnresolvedDirtyBits(); |
for (Frame* child = m_layoutView.frameView()->frame().tree().firstChild(); child; child = child->tree().nextSibling()) { |
- if (child->isLocalFrame()) |
- toLocalFrame(child)->contentLayoutObject()->compositor()->assertNoUnresolvedDirtyBits(); |
+ if (!child->isLocalFrame()) |
+ continue; |
+ LocalFrame* localFrame = toLocalFrame(child); |
+ if (localFrame->shouldThrottleStyleLayoutAndCompositingUpdates()) |
+ continue; |
+ localFrame->contentLayoutObject()->compositor()->assertNoUnresolvedDirtyBits(); |
} |
#endif |
} |
@@ -608,7 +616,7 @@ bool DeprecatedPaintLayerCompositor::scrollingLayerDidChange(DeprecatedPaintLaye |
String DeprecatedPaintLayerCompositor::layerTreeAsText(LayerTreeFlags flags) |
{ |
- ASSERT(lifecycle().state() >= DocumentLifecycle::PaintInvalidationClean); |
+ ASSERT(lifecycle().state() >= DocumentLifecycle::PaintInvalidationClean || (m_layoutView.frameView() && m_layoutView.frameView()->shouldThrottleRenderingPipeline())); |
if (!m_rootContentLayer) |
return String(); |
@@ -872,12 +880,15 @@ void DeprecatedPaintLayerCompositor::resetTrackedPaintInvalidationRects() |
void DeprecatedPaintLayerCompositor::setTracksPaintInvalidations(bool tracksPaintInvalidations) |
{ |
#if ENABLE(ASSERT) |
+ FrameView* view = m_layoutView.frameView(); |
if (RuntimeEnabledFeatures::slimmingPaintV2Enabled()) { |
ASSERT(lifecycle().state() == DocumentLifecycle::CompositingForSlimmingPaintV2Clean |
// TODO(wangxianzhu): Remove this when we remove the old path for spv2. |
- || lifecycle().state() == DocumentLifecycle::PaintInvalidationClean); |
+ || lifecycle().state() == DocumentLifecycle::PaintInvalidationClean |
+ || (view && view->shouldThrottleRenderingPipeline())); |
} else { |
- ASSERT(lifecycle().state() == DocumentLifecycle::PaintInvalidationClean); |
+ ASSERT(lifecycle().state() == DocumentLifecycle::PaintInvalidationClean |
+ || (view && view->shouldThrottleRenderingPipeline())); |
} |
#endif |