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

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

Issue 1364063007: Throttle rendering pipeline for invisible frames (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix layout test by not dumping throttled FrameViews. Created 5 years, 2 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/LayoutPart.cpp
diff --git a/third_party/WebKit/Source/core/layout/LayoutPart.cpp b/third_party/WebKit/Source/core/layout/LayoutPart.cpp
index c8f01f97c2e717ca604cb21ee92ec8794d895b8c..c22e254ddc059d2cb671771355f087ab654f10bc 100644
--- a/third_party/WebKit/Source/core/layout/LayoutPart.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutPart.cpp
@@ -357,4 +357,12 @@ void LayoutPart::invalidatePaintOfSubtreesIfNeeded(PaintInvalidationState& paint
LayoutReplaced::invalidatePaintOfSubtreesIfNeeded(paintInvalidationState);
}
+bool LayoutPart::isThrottledFrameView() const
+{
+ if (!widget() || !widget()->isFrameView())
+ return false;
+ const FrameView* frameView = toFrameView(widget());
+ return frameView->shouldThrottleRendering();
+}
+
}

Powered by Google App Engine
This is Rietveld 408576698