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

Unified Diff: Source/core/rendering/RenderBox.cpp

Issue 341523002: Resolve percent lengths for abs. positioned tables against padding box. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 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: Source/core/rendering/RenderBox.cpp
diff --git a/Source/core/rendering/RenderBox.cpp b/Source/core/rendering/RenderBox.cpp
index 92909837daab0c2cdb153ab6dced0a56b7772107..9a09f6a94673ef34737d88967bd9356281670f62 100644
--- a/Source/core/rendering/RenderBox.cpp
+++ b/Source/core/rendering/RenderBox.cpp
@@ -2770,6 +2770,9 @@ LayoutUnit RenderBox::computePercentageLogicalHeight(const Length& height) const
availableHeight -= rootMarginBorderPaddingHeight;
+ if (isTable() && isOutOfFlowPositioned())
+ availableHeight += cb->paddingLogicalHeight();
+
LayoutUnit result = valueForLength(height, availableHeight);
if (includeBorderPadding) {
// FIXME: Table cells should default to box-sizing: border-box so we can avoid this hack.

Powered by Google App Engine
This is Rietveld 408576698