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

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

Issue 1755243002: Partly revert of Conditionally create PaintLayer's scrollable area object (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@PaintLayerClipper
Patch Set: Partly revert 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
« no previous file with comments | « third_party/WebKit/Source/core/paint/PaintLayer.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 2e2dad8652dfdc483909dd54fe394fa462126c20..4ae5132c89708c12992b47244806223ba351709d 100644
--- a/third_party/WebKit/Source/core/paint/PaintLayer.cpp
+++ b/third_party/WebKit/Source/core/paint/PaintLayer.cpp
@@ -1469,14 +1469,9 @@ void PaintLayer::updateStackingNode()
void PaintLayer::updateScrollableArea()
{
- if (requiresScrollableArea()) {
- if (!m_scrollableArea)
- m_scrollableArea = PaintLayerScrollableArea::create(*this);
- } else if (m_scrollableArea) {
- if (m_scrollableArea)
- m_scrollableArea->dispose();
- m_scrollableArea.clear();
- }
+ ASSERT(!m_scrollableArea);
+ if (requiresScrollableArea())
+ m_scrollableArea = PaintLayerScrollableArea::create(*this);
}
bool PaintLayer::hasOverflowControls() const
@@ -2582,7 +2577,6 @@ void PaintLayer::styleChanged(StyleDifference diff, const ComputedStyle* oldStyl
m_stackingNode->updateIsTreatedAsStackingContext();
m_stackingNode->updateStackingNodesAfterStyleChange(oldStyle);
- updateScrollableArea();
if (m_scrollableArea)
m_scrollableArea->updateAfterStyleChange(oldStyle);
« no previous file with comments | « third_party/WebKit/Source/core/paint/PaintLayer.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698