Bug 404146. Simplifying the code a little

This commit is contained in:
roc+@cs.cmu.edu 2008-01-09 19:23:35 -08:00
parent c741cddc02
commit f20b4931ec

View File

@ -661,9 +661,9 @@ nsContainerFrame::DoInlineIntrinsicWidth(nsIRenderingContext *aRenderingContext,
GetCoord(styleMargin->mMargin.Get(startSide, tmp), 0);
const nsLineList_iterator* savedLine = aData->line;
nsContainerFrame* next;
for (nsContainerFrame *nif = this; nif; nif = next) {
for (nsContainerFrame *nif = this; nif;
nif = (nsContainerFrame*) nif->GetNextInFlow()) {
for (nsIFrame *kid = nif->mFrames.FirstChild(); kid;
kid = kid->GetNextSibling()) {
if (aType == nsLayoutUtils::MIN_WIDTH)
@ -674,12 +674,9 @@ nsContainerFrame::DoInlineIntrinsicWidth(nsIRenderingContext *aRenderingContext,
static_cast<InlinePrefWidthData*>(aData));
}
next = (nsContainerFrame*) nif->GetNextInFlow();
if (next) {
// After we advance to our next-in-flow, the stored line may no
// longer be the correct line. Just forget it.
aData->line = nsnull;
}
// After we advance to our next-in-flow, the stored line may not
// longer be the correct line. Just forget it.
aData->line = nsnull;
}
aData->line = savedLine;