From 415b49472bfee5d6ea8a29dbeb82fd579feb808a Mon Sep 17 00:00:00 2001 From: "scott%scott-macgregor.org" Date: Fri, 11 Jun 2004 19:54:13 +0000 Subject: [PATCH] Back out Bug #217527 --> {inc}left column on slashdot is sometimes too narrow or too wide for its contents as it caused a regression on the 1.7 branch git-svn-id: svn://10.0.0.236/branches/AVIARY_1_0_20040515_BRANCH@157798 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/layout/html/base/src/nsBlockFrame.cpp | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/mozilla/layout/html/base/src/nsBlockFrame.cpp b/mozilla/layout/html/base/src/nsBlockFrame.cpp index 0a081a8c7b1..b1d5d27c110 100644 --- a/mozilla/layout/html/base/src/nsBlockFrame.cpp +++ b/mozilla/layout/html/base/src/nsBlockFrame.cpp @@ -2423,14 +2423,17 @@ nsBlockFrame::ReflowLine(nsBlockReflowState& aState, aState.UpdateMaximumWidth(aLine->mMaximumWidth); // Now reflow the line again this time without having it compute - // the maximum width. - // We leave whether to compute max-element-width as-is, because - // making this call throws out the previous max-element-width - // information stored in the float cache. + // the maximum width or max-element-width. + // Note: we need to reset both member variables, because the inline + // code examines mComputeMaxElementWidth and if there is a placeholder + // on this line the code to reflow the float looks at both... + nscoord oldComputeMaxElementWidth = aState.GetFlag(BRS_COMPUTEMAXELEMENTWIDTH); nscoord oldComputeMaximumWidth = aState.GetFlag(BRS_COMPUTEMAXWIDTH); + aState.SetFlag(BRS_COMPUTEMAXELEMENTWIDTH, PR_FALSE); aState.SetFlag(BRS_COMPUTEMAXWIDTH, PR_FALSE); rv = ReflowInlineFrames(aState, aLine, aKeepReflowGoing, aDamageDirtyArea); + aState.SetFlag(BRS_COMPUTEMAXELEMENTWIDTH, oldComputeMaxElementWidth); aState.SetFlag(BRS_COMPUTEMAXWIDTH, oldComputeMaximumWidth); } else {