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

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

Issue 2065243003: [css-sizing] Ensure positive available size on replaced elements Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: A different approach. Created 4 years, 1 month 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/LayoutReplaced.cpp
diff --git a/third_party/WebKit/Source/core/layout/LayoutReplaced.cpp b/third_party/WebKit/Source/core/layout/LayoutReplaced.cpp
index f9822157bb6549f5d03c19b554367585db36a873..f3cd01520133bbdec9a1bae34546253bedcc96d9 100644
--- a/third_party/WebKit/Source/core/layout/LayoutReplaced.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutReplaced.cpp
@@ -824,7 +824,11 @@ void LayoutReplaced::computePreferredLogicalWidths() {
// containing block.
const Length& logicalWidth = style()->logicalWidth();
if (logicalWidth.isPercentOrCalc() || logicalWidth.isFillAvailable() ||
- logicalWidth.isFitContent())
+ logicalWidth.isFitContent() ||
+ (logicalWidth.isAuto() && (style()->logicalMinWidth().isFillAvailable() ||
+ style()->logicalMinWidth().isFitContent() ||
mstensho (USE GERRIT) 2016/11/10 19:54:25 Why no isPercentOrCalc() here?
jfernandez 2016/11/10 20:54:39 umm, not sure, I thought about that. I tried to ke
+ style()->logicalMaxWidth().isFillAvailable() ||
+ style()->logicalMaxWidth().isFitContent())))
computeIntrinsicLogicalWidths(m_minPreferredLogicalWidth,
m_maxPreferredLogicalWidth);
else

Powered by Google App Engine
This is Rietveld 408576698