Bug 45631: text-indent: n% doesn't incrementally reflow correctly. r+sr=roc.

This commit is contained in:
sharparrow1@yahoo.com 2007-05-21 02:55:27 -07:00
parent 6c7820f159
commit 3fb1602073
2 changed files with 6 additions and 1 deletions

View File

@ -3204,6 +3204,11 @@ nsBlockFrame::DoReflowInlineFrames(nsBlockReflowState& aState,
/* XXX get the height right! */
availHeight = aState.mAvailSpaceRect.height;
}
// Make sure to enable resize optimization before we call BeginLineReflow
// because it might get disabled there
aLine->EnableResizeReflowOptimization();
aLineLayout.BeginLineReflow(x, aState.mY,
availWidth, availHeight,
impactedByFloats,
@ -3224,7 +3229,6 @@ nsBlockFrame::DoReflowInlineFrames(nsBlockReflowState& aState,
LineReflowStatus lineReflowStatus = LINE_REFLOW_OK;
PRInt32 i;
nsIFrame* frame = aLine->mFirstChild;
aLine->EnableResizeReflowOptimization();
// Determine whether this is a line of placeholders for out-of-flow
// continuations

View File

@ -249,6 +249,7 @@ nsLineLayout::BeginLineReflow(nscoord aX, nscoord aY,
if ((0 != width) && (NS_UNCONSTRAINEDSIZE != width)) {
indent = nscoord(mStyleText->mTextIndent.GetPercentValue() * width);
}
mLineBox->DisableResizeReflowOptimization();
}
mTextIndent = indent;