| Index: third_party/WebKit/Source/core/paint/PaintLayer.cpp
|
| diff --git a/third_party/WebKit/Source/core/paint/PaintLayer.cpp b/third_party/WebKit/Source/core/paint/PaintLayer.cpp
|
| index 168383e4077bc5da12b3a5d8b84841d30bb4efcc..d891178e1a9a6d36b791cd61f37a209754dde810 100644
|
| --- a/third_party/WebKit/Source/core/paint/PaintLayer.cpp
|
| +++ b/third_party/WebKit/Source/core/paint/PaintLayer.cpp
|
| @@ -47,6 +47,7 @@
|
| #include "core/CSSPropertyNames.h"
|
| #include "core/HTMLNames.h"
|
| #include "core/css/PseudoStyleRequest.h"
|
| +#include "core/dom/ClientRectList.h"
|
| #include "core/dom/Document.h"
|
| #include "core/dom/shadow/ShadowRoot.h"
|
| #include "core/frame/FrameView.h"
|
| @@ -3198,6 +3199,18 @@ void PaintLayer::clearNeedsRepaintRecursively() {
|
| m_needsRepaint = false;
|
| }
|
|
|
| +ClientRectList* PaintLayer::nonFastScrollableRects() const {
|
| + // This bypasses the isAllowedToQueryCompositingState() check to enabled the
|
| + // optimization from https://codereview.chromium.org/1256043007
|
| + CompositedLayerMapping* clm =
|
| + m_rareData ? m_rareData->compositedLayerMapping.get() : nullptr;
|
| + if (!clm || !clm->scrollingContentsLayer())
|
| + return ClientRectList::create();
|
| + return ClientRectList::create(clm->scrollingContentsLayer()
|
| + ->platformLayer()
|
| + ->nonFastScrollableRegion());
|
| +}
|
| +
|
| #if CHECK_DISPLAY_ITEM_CLIENT_ALIVENESS
|
| void PaintLayer::endShouldKeepAliveAllClientsRecursive() {
|
| for (PaintLayer* child = firstChild(); child; child = child->nextSibling())
|
|
|