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

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

Issue 842193004: [css-grid] Handle alignment with orthogonal flows (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@orthogonal-flows
Patch Set: Patch rebased. Created 4 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: 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 2dae9193d9c32f32b75eeb6aa231e20bf0b40965..559430f2979a23485db7057c2a783af235b29758 100644
--- a/third_party/WebKit/Source/core/layout/LayoutBox.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutBox.cpp
@@ -1147,6 +1147,26 @@ void LayoutBox::clearOverrideContainingBlockContentLogicalHeight()
gOverrideContainingBlockLogicalHeightMap->remove(this);
}
+LayoutUnit LayoutBox::overrideContainingBlockContentWidth() const
+{
+ return containingBlock()->isHorizontalWritingMode() ? overrideContainingBlockContentLogicalWidth() : overrideContainingBlockContentLogicalHeight();
+}
+
+LayoutUnit LayoutBox::overrideContainingBlockContentHeight() const
+{
+ return containingBlock()->isHorizontalWritingMode() ? overrideContainingBlockContentLogicalHeight() : overrideContainingBlockContentLogicalWidth();
+}
+
+bool LayoutBox::hasOverrideContainingBlockWidth() const
+{
+ return containingBlock()->isHorizontalWritingMode() ? hasOverrideContainingBlockLogicalHeight() : hasOverrideContainingBlockLogicalWidth();
svillar 2016/07/13 09:00:40 Aren't logical height and width flipped here? If
jfernandez 2016/07/14 09:29:15 Yes, they are. Good catch !!!
+}
+
+bool LayoutBox::hasOverrideContainingBlockHeight() const
+{
+ return containingBlock()->isHorizontalWritingMode() ? hasOverrideContainingBlockLogicalHeight() : hasOverrideContainingBlockLogicalWidth();
+}
+
LayoutUnit LayoutBox::extraInlineOffset() const
{
return gExtraInlineOffsetMap ? gExtraInlineOffsetMap->get(this) : LayoutUnit();

Powered by Google App Engine
This is Rietveld 408576698