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

Unified Diff: third_party/WebKit/Source/core/paint/PaintLayer.h

Issue 1643663002: Conditionally create PaintLayer's scrollable area object (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@PaintLayerClipper
Patch Set: Created 4 years, 10 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/paint/PaintLayer.h
diff --git a/third_party/WebKit/Source/core/paint/PaintLayer.h b/third_party/WebKit/Source/core/paint/PaintLayer.h
index 473f4583c086fff13d2dca5fc8ce5abccda588f6..ccd79f249db8096dacf60324f06c1af4a52dbc88 100644
--- a/third_party/WebKit/Source/core/paint/PaintLayer.h
+++ b/third_party/WebKit/Source/core/paint/PaintLayer.h
@@ -740,9 +740,7 @@ private:
void updateReflectionInfo(const ComputedStyle*);
FilterEffectBuilder* updateFilterEffectBuilder() const;
- // FIXME: We could lazily allocate our ScrollableArea based on style properties ('overflow', ...)
- // but for now, we are always allocating it for LayoutBox as it's safer. crbug.com/467721.
- bool requiresScrollableArea() const { return layoutBox(); }
+ bool requiresScrollableArea() const { return m_layoutObject->hasOverflowClip() || m_layoutObject->isLayoutView() || m_layoutObject->styleRef().resize() != RESIZE_NONE; }
void updateScrollableArea();
void dirtyAncestorChainVisibleDescendantStatus();

Powered by Google App Engine
This is Rietveld 408576698