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

Unified Diff: Source/core/layout/LayoutTableSection.cpp

Issue 1023133002: Negative row height when cell has percentage height. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase Created 5 years, 4 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
« no previous file with comments | « LayoutTests/fast/table/table-rowspan-row-height-less-than-content-height-expected.txt ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/layout/LayoutTableSection.cpp
diff --git a/Source/core/layout/LayoutTableSection.cpp b/Source/core/layout/LayoutTableSection.cpp
index 63e6a0815f5e165059929d22ba614ee60cbeb0a4..13715dbd10623afcc0edecbfdecc50b7cad9f90b 100644
--- a/Source/core/layout/LayoutTableSection.cpp
+++ b/Source/core/layout/LayoutTableSection.cpp
@@ -322,7 +322,7 @@ void LayoutTableSection::distributeExtraRowSpanHeightToPercentRows(LayoutTableCe
// FIXME: Note that this is wrong if we have a percentage above 100% and may make us grow
// above the available space.
- toAdd = std::min(toAdd, extraRowSpanningHeight);
+ toAdd = std::max(std::min(toAdd, extraRowSpanningHeight), 0);
accumulatedPositionIncrease += toAdd;
extraRowSpanningHeight -= toAdd;
percent -= m_grid[row].logicalHeight.percent();
« no previous file with comments | « LayoutTests/fast/table/table-rowspan-row-height-less-than-content-height-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698