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

Unified Diff: Source/core/layout/LayoutObject.cpp

Issue 1212893005: Add position: sticky as supported position value when CSSStickyPosition is enabled. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Comments and merge. 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
Index: Source/core/layout/LayoutObject.cpp
diff --git a/Source/core/layout/LayoutObject.cpp b/Source/core/layout/LayoutObject.cpp
index dd8196f6431d8f97f0899ba661e2d853398328ff..7847c097e6e5070d4773099b6d4b6cae8cf47325 100644
--- a/Source/core/layout/LayoutObject.cpp
+++ b/Source/core/layout/LayoutObject.cpp
@@ -1081,6 +1081,8 @@ String LayoutObject::decoratedName() const
name.append(" (positioned)");
if (isRelPositioned())
name.append(" (relative positioned)");
+ if (isStickyPositioned())
+ name.append(" (sticky positioned)");
if (isFloating())
name.append(" (floating)");
if (spannerPlaceholder())
@@ -1972,7 +1974,7 @@ void LayoutObject::propagateStyleToAnonymousChildren(bool blockChildrenOnly)
// Preserve the position style of anonymous block continuations as they can have relative position when
// they contain block descendants of relative positioned inlines.
- if (child->isRelPositioned() && toLayoutBlock(child)->isAnonymousBlockContinuation())
+ if (child->isInFlowPositioned() && toLayoutBlock(child)->isAnonymousBlockContinuation())
newStyle->setPosition(child->style()->position());
updateAnonymousChildStyle(*child, *newStyle);

Powered by Google App Engine
This is Rietveld 408576698