From 2874c6e6fc682b31b3039beaf3f5ab3caaeddec4 Mon Sep 17 00:00:00 2001 From: Mats Palmgren Date: Wed, 2 Dec 2015 14:12:23 +0100 Subject: [PATCH] Bug 1227285 part 2 - [css-grid] Request shrink-wrap behavior when doing a measuring reflow to figure out a grid item's block-size. r=dholbert --- layout/generic/nsGridContainerFrame.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/layout/generic/nsGridContainerFrame.cpp b/layout/generic/nsGridContainerFrame.cpp index 123091a4bc8e..88f56e3ce2e9 100644 --- a/layout/generic/nsGridContainerFrame.cpp +++ b/layout/generic/nsGridContainerFrame.cpp @@ -2014,7 +2014,8 @@ ContentContribution(nsIFrame* aChild, #endif // XXX this will give mostly correct results for now (until bug 1174569). LogicalSize availableSize(wm, INFINITE_ISIZE_COORD, NS_UNCONSTRAINEDSIZE); - nsHTMLReflowState childRS(pc, *rs, aChild, availableSize); + nsHTMLReflowState childRS(pc, *rs, aChild, availableSize, nullptr, + nsHTMLReflowState::COMPUTE_SIZE_SHRINK_WRAP); nsHTMLReflowMetrics childSize(childRS); nsReflowStatus childStatus; const uint32_t flags = NS_FRAME_NO_MOVE_FRAME | NS_FRAME_NO_SIZE_VIEW;