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

Unified Diff: Source/core/paint/DeprecatedPaintLayer.h

Issue 1199673003: Have enclosingPositionedAncestor() detect whether it walked past a certain ancestor. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: code review Created 5 years, 6 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 | « no previous file | Source/core/paint/DeprecatedPaintLayer.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/paint/DeprecatedPaintLayer.h
diff --git a/Source/core/paint/DeprecatedPaintLayer.h b/Source/core/paint/DeprecatedPaintLayer.h
index a32f7d68019a8617f67f014359284f9734ab23a1..b38dd5023aabf791c975acce9039ffb4e0abf5c3 100644
--- a/Source/core/paint/DeprecatedPaintLayer.h
+++ b/Source/core/paint/DeprecatedPaintLayer.h
@@ -195,9 +195,14 @@ public:
bool hasVisibleNonLayerContent() const { return m_hasVisibleNonLayerContent; }
bool hasNonCompositedChild() const { ASSERT(isAllowedToQueryCompositingState()); return m_hasNonCompositedChild; }
- // Gets the nearest enclosing positioned ancestor layer (also includes
- // the <html> layer and the root layer).
- DeprecatedPaintLayer* enclosingPositionedAncestor() const;
+ // Gets the ancestor layer that serves as the containing block of this layer. It is assumed
+ // that this layer is established by an out-of-flow positioned layout object (i.e. either
+ // absolutely or fixed positioned).
+ // If |ancestor| is specified, |*skippedAncestor| will be set to true if |ancestor| is found in
+ // the ancestry chain between this layer and the containing block layer; if not found, it will
+ // be set to false. Either both |ancestor| and |skippedAncestor| should be nullptr, or none of
+ // them should.
+ DeprecatedPaintLayer* enclosingPositionedAncestor(const DeprecatedPaintLayer* ancestor = nullptr, bool* skippedAncestor = nullptr) const;
bool isPaintInvalidationContainer() const;
« no previous file with comments | « no previous file | Source/core/paint/DeprecatedPaintLayer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698