Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(95)

Unified Diff: third_party/WebKit/Source/core/layout/LayoutObject.cpp

Issue 1246173002: Throttle rendering pipeline for invisible iframes (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebased to post merge awesomeness. Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/layout/LayoutObject.cpp
diff --git a/third_party/WebKit/Source/core/layout/LayoutObject.cpp b/third_party/WebKit/Source/core/layout/LayoutObject.cpp
index 80565df0ef762904c649c481e51d244adfde82f2..61313bde290021e1e56ca0fafacd2286727a4194 100644
--- a/third_party/WebKit/Source/core/layout/LayoutObject.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutObject.cpp
@@ -3174,7 +3174,8 @@ void LayoutObject::setShouldDoFullPaintInvalidation(PaintInvalidationReason reas
if (!isUpgradingDelayedFullToFull) {
ASSERT(document().lifecycle().state() != DocumentLifecycle::InPaintInvalidation);
- frame()->page()->animator().scheduleVisualUpdate(); // In case that this is called outside of FrameView::updateLayoutAndStyleForPainting().
+ if (!frameView() || !frameView()->shouldThrottleRenderingPipeline())
+ frame()->page()->animator().scheduleVisualUpdate(); // In case that this is called outside of FrameView::updateLayoutAndStyleForPainting().
markContainerChainForPaintInvalidation();
}
}
@@ -3185,7 +3186,8 @@ void LayoutObject::setMayNeedPaintInvalidation()
return;
m_bitfields.setMayNeedPaintInvalidation(true);
markContainerChainForPaintInvalidation();
- frame()->page()->animator().scheduleVisualUpdate(); // In case that this is called outside of FrameView::updateLayoutAndStyleForPainting().
+ if (!frameView() || !frameView()->shouldThrottleRenderingPipeline())
+ frame()->page()->animator().scheduleVisualUpdate(); // In case that this is called outside of FrameView::updateLayoutAndStyleForPainting().
}
void LayoutObject::clearPaintInvalidationState(const PaintInvalidationState& paintInvalidationState)

Powered by Google App Engine
This is Rietveld 408576698