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

Unified Diff: third_party/WebKit/Source/core/layout/ng/ng_length_utils.cc

Issue 2969433002: [LayoutNG] Add min/max-{width,height} to instrinics check for abs-pos (Closed)
Patch Set: spelling. Created 3 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/ng/ng_length_utils.cc
diff --git a/third_party/WebKit/Source/core/layout/ng/ng_length_utils.cc b/third_party/WebKit/Source/core/layout/ng/ng_length_utils.cc
index 9e5d76a5de5b8b2293f725f45e77a04d408f3a25..a6b7fd2158edaccebf014abe321be5b660ca60ff 100644
--- a/third_party/WebKit/Source/core/layout/ng/ng_length_utils.cc
+++ b/third_party/WebKit/Source/core/layout/ng/ng_length_utils.cc
@@ -22,8 +22,11 @@ bool NeedMinMaxContentSize(const NGConstraintSpace& constraint_space,
// This check is technically too broad (fill-available does not need intrinsic
// size computation) but that's a rare case and only affects performance, not
// correctness.
- return constraint_space.IsShrinkToFit() ||
- style.LogicalWidth().IsIntrinsic() ||
+ return constraint_space.IsShrinkToFit() || NeedMinMaxContentSize(style);
+}
+
+bool NeedMinMaxContentSize(const ComputedStyle& style) {
+ return style.LogicalWidth().IsIntrinsic() ||
style.LogicalMinWidth().IsIntrinsic() ||
style.LogicalMaxWidth().IsIntrinsic();
}

Powered by Google App Engine
This is Rietveld 408576698