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

Unified Diff: third_party/WebKit/Source/core/layout/LayoutBox.cpp

Issue 1709963002: [css-align] New CSS Value 'normal' for Self Alignment (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Unskipped some repaint tests and rebaselined. Created 4 years, 7 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/layout/LayoutBox.cpp
diff --git a/third_party/WebKit/Source/core/layout/LayoutBox.cpp b/third_party/WebKit/Source/core/layout/LayoutBox.cpp
index 7be475bd7ae129ad8e1d459570defd90960c1736..1b46f4db85e5734611ecdedbb6808d3b6a5da836 100644
--- a/third_party/WebKit/Source/core/layout/LayoutBox.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutBox.cpp
@@ -2367,7 +2367,7 @@ static bool columnFlexItemHasStretchAlignment(const LayoutObject* flexitem)
ASSERT(parent->style()->isColumnFlexDirection());
if (flexitem->style()->marginStart().isAuto() || flexitem->style()->marginEnd().isAuto())
return false;
- return flexitem->style()->alignSelfPosition() == ItemPositionStretch || (flexitem->style()->alignSelfPosition() == ItemPositionAuto && parent->style()->alignItemsPosition() == ItemPositionStretch);
+ return flexitem->styleRef().resolvedAlignSelf(parent->styleRef(), ItemPositionStretch).position() == ItemPositionStretch;
}
static bool isStretchingColumnFlexItem(const LayoutObject* flexitem)
@@ -2395,8 +2395,8 @@ bool LayoutBox::hasStretchedLogicalWidth() const
return false;
}
if (cb->isHorizontalWritingMode() != isHorizontalWritingMode())
- return ComputedStyle::resolveAlignment(cb->styleRef(), style, ItemPositionStretch) == ItemPositionStretch;
- return ComputedStyle::resolveJustification(cb->styleRef(), style, ItemPositionStretch) == ItemPositionStretch;
+ return style.resolvedAlignSelf(cb->styleRef(), ItemPositionStretch).position() == ItemPositionStretch;
+ return style.resolvedJustifySelf(cb->styleRef(), ItemPositionStretch).position() == ItemPositionStretch;
}
bool LayoutBox::sizesLogicalWidthToFitContent(const Length& logicalWidth) const

Powered by Google App Engine
This is Rietveld 408576698