Bug 1103613 - Use better inline-size for an orthogonal flow within a block of specified dimensions. r=smontagu

This commit is contained in:
Jonathan Kew 2014-11-24 21:44:06 +00:00
Родитель c17b663150
Коммит 9a4427f454
1 изменённых файлов: 10 добавлений и 0 удалений

Просмотреть файл

@ -192,6 +192,16 @@ nsHTMLReflowState::nsHTMLReflowState(nsPresContext* aPresContext,
AvailableISize() = aAvailableSpace.ISize(mWritingMode);
AvailableBSize() = aAvailableSpace.BSize(mWritingMode);
if (mWritingMode.IsOrthogonalTo(aParentReflowState.GetWritingMode())) {
// If we're setting up for an orthogonal flow, and the parent reflow state
// had a constrained ComputedBSize, we can use that as our AvailableISize
// in preference to leaving it unconstrained.
if (AvailableISize() == NS_UNCONSTRAINEDSIZE &&
aParentReflowState.ComputedBSize() != NS_UNCONSTRAINEDSIZE) {
AvailableISize() = aParentReflowState.ComputedBSize();
}
}
mFloatManager = aParentReflowState.mFloatManager;
if (frame->IsFrameOfType(nsIFrame::eLineParticipant))
mLineLayout = aParentReflowState.mLineLayout;