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

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

Issue 1610063002: Revert of Remove PaintInfo's paintingRoot (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 11 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/PaintInfo.cpp
diff --git a/third_party/WebKit/Source/core/paint/PaintInfo.cpp b/third_party/WebKit/Source/core/paint/PaintInfo.cpp
index 7ada3bcde613dbf473b6b32227dc987b5796959d..91de13e37a6ed8730dd3b5c96f6b988216a65ad4 100644
--- a/third_party/WebKit/Source/core/paint/PaintInfo.cpp
+++ b/third_party/WebKit/Source/core/paint/PaintInfo.cpp
@@ -6,6 +6,23 @@
namespace blink {
+void PaintInfo::updatePaintingRootForChildren(const LayoutObject* layoutObject)
+{
+ if (!paintingRoot)
+ return;
+
+ // If we're the painting root, kids draw normally, and see root of nullptr.
+ if (paintingRoot == layoutObject) {
+ paintingRoot = nullptr;
+ return;
+ }
+}
+
+bool PaintInfo::shouldPaintWithinRoot(const LayoutObject* layoutObject) const
+{
+ return !paintingRoot || paintingRoot == layoutObject;
+}
+
void PaintInfo::updateCullRect(const AffineTransform& localToParentTransform)
{
m_cullRect.updateCullRect(localToParentTransform);
« no previous file with comments | « third_party/WebKit/Source/core/paint/PaintInfo.h ('k') | third_party/WebKit/Source/core/paint/PaintLayerPainter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698