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

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

Issue 2111623002: Canvas objects did not mark themselves for layout when they're a flex item (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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/LayoutFlexibleBox.cpp
diff --git a/third_party/WebKit/Source/core/layout/LayoutFlexibleBox.cpp b/third_party/WebKit/Source/core/layout/LayoutFlexibleBox.cpp
index 7e2becde31d1c2cfad97cc4ed0bdaad29c3d9942..8287bc0de2980bba7b1d271ee9c78a6b7be2fa07 100644
--- a/third_party/WebKit/Source/core/layout/LayoutFlexibleBox.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutFlexibleBox.cpp
@@ -476,7 +476,10 @@ LayoutUnit LayoutFlexibleBox::childIntrinsicWidth(const LayoutBox& child) const
{
if (!child.isHorizontalWritingMode() && needToStretchChildLogicalHeight(child))
return constrainedChildIntrinsicContentLogicalHeight(child);
- // TOOO(cbiesinger): should this return the maxPreferredLogicalWidth?
+ if (child.isHorizontalWritingMode() && child.styleRef().width().isAuto()) {
+ // This value is already clamped by min/max-width
+ return child.maxPreferredLogicalWidth();
+ }
return child.size().width();
}
@@ -832,7 +835,7 @@ LayoutUnit LayoutFlexibleBox::computeInnerFlexBaseSizeForChild(LayoutBox& child,
if (childLayoutType == NeverLayout)
return LayoutUnit();
- if (child.needsLayout() || childLayoutType == ForceLayout || !m_intrinsicSizeAlongMainAxis.contains(&child)) {
+ if (1 || child.needsLayout() || childLayoutType == ForceLayout || !m_intrinsicSizeAlongMainAxis.contains(&child)) {
eae 2016/06/29 20:20:13 You probably forgot to remove this...
cbiesinger 2016/06/29 20:36:51 Yeah, included this entire file by accident :/
child.forceChildLayout();
cacheChildMainSize(child);
}

Powered by Google App Engine
This is Rietveld 408576698