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

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

Issue 2065243003: [css-sizing] Ensure positive available size on replaced elements Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebaselined test. Created 3 years, 11 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 3ad08c2f8690a0b53c26c12ddbb85d11157304f1..0bf81671d453f097ea087df6c0847636509b4e3f 100644
--- a/third_party/WebKit/Source/core/layout/LayoutBox.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutBox.cpp
@@ -3269,14 +3269,15 @@ LayoutUnit LayoutBox::computeReplacedLogicalWidth(
LayoutUnit LayoutBox::computeReplacedLogicalWidthRespectingMinMaxWidth(
LayoutUnit logicalWidth,
ShouldComputePreferred shouldComputePreferred) const {
- LayoutUnit minLogicalWidth = (shouldComputePreferred == ComputePreferred &&
- style()->logicalMinWidth().isPercentOrCalc())
- ? logicalWidth
- : computeReplacedLogicalWidthUsing(
- MinSize, style()->logicalMinWidth());
+ LayoutUnit minLogicalWidth =
+ shouldComputePreferred == ComputePreferred &&
+ style()->logicalMinWidth().isLayoutDependent()
+ ? logicalWidth
+ : computeReplacedLogicalWidthUsing(MinSize,
+ style()->logicalMinWidth());
LayoutUnit maxLogicalWidth =
(shouldComputePreferred == ComputePreferred &&
- style()->logicalMaxWidth().isPercentOrCalc()) ||
+ style()->logicalMaxWidth().isLayoutDependent()) ||
style()->logicalMaxWidth().isMaxSizeNone()
? logicalWidth
: computeReplacedLogicalWidthUsing(MaxSize,

Powered by Google App Engine
This is Rietveld 408576698