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

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

Issue 2750463003: Reduce the number of ObjectPaintProperties (Closed)
Patch Set: Created 3 years, 9 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/PaintPropertyTreeBuilder.cpp
diff --git a/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp b/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp
index acc863efbb333203a64786c8178ca436024d73c9..247d41b8d2ed7c8bd5f7a7da7f2b0150a73e79a3 100644
--- a/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp
+++ b/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp
@@ -683,9 +683,8 @@ void PaintPropertyTreeBuilder::updateLocalBorderBoxContext(
if (!object.needsPaintPropertyUpdate() && !context.forceSubtreeUpdate)
return;
- // Avoid adding an ObjectPaintProperties for non-boxes to save memory, since
- // we don't need them at the moment.
- if (!object.isBox() && !object.hasLayer()) {
+ // We need localBorderBoxProperties for layered objects only.
+ if (!object.hasLayer()) {
if (auto* properties = object.getMutableForPainting().paintProperties())
properties->clearLocalBorderBoxProperties();
} else {

Powered by Google App Engine
This is Rietveld 408576698