From 897a892fa0db891d2e56ad57224c16bdc0318064 Mon Sep 17 00:00:00 2001 From: "dbaron%dbaron.org" Date: Fri, 22 Oct 2004 17:33:52 +0000 Subject: [PATCH] Don't push lines when height is unconstrained, even if current height is bigger than NS_UNCONSTRAINEDSIZE. b=265027 r+sr=roc a=mkaply git-svn-id: svn://10.0.0.236/trunk@164194 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/layout/generic/nsBlockFrame.cpp | 6 ++++-- mozilla/layout/html/base/src/nsBlockFrame.cpp | 6 ++++-- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/mozilla/layout/generic/nsBlockFrame.cpp b/mozilla/layout/generic/nsBlockFrame.cpp index 88d744f4a54..37f994875ea 100644 --- a/mozilla/layout/generic/nsBlockFrame.cpp +++ b/mozilla/layout/generic/nsBlockFrame.cpp @@ -4178,8 +4178,10 @@ nsBlockFrame::PlaceLine(nsBlockReflowState& aState, // fits; we'll assume it does, so that the maximum width will get // updated below. The line will be reflowed again and pushed then // if necessary. - if ((mLines.front() != aLine) && (newY > aState.mBottomEdge) - && !aUpdateMaximumWidth) { + if (mLines.front() != aLine && + newY > aState.mBottomEdge && + aState.mBottomEdge != NS_UNCONSTRAINEDSIZE && + !aUpdateMaximumWidth) { // Push this line and all of it's children and anything else that // follows to our next-in-flow NS_ASSERTION((aState.mCurrentLine == aLine), "oops"); diff --git a/mozilla/layout/html/base/src/nsBlockFrame.cpp b/mozilla/layout/html/base/src/nsBlockFrame.cpp index 88d744f4a54..37f994875ea 100644 --- a/mozilla/layout/html/base/src/nsBlockFrame.cpp +++ b/mozilla/layout/html/base/src/nsBlockFrame.cpp @@ -4178,8 +4178,10 @@ nsBlockFrame::PlaceLine(nsBlockReflowState& aState, // fits; we'll assume it does, so that the maximum width will get // updated below. The line will be reflowed again and pushed then // if necessary. - if ((mLines.front() != aLine) && (newY > aState.mBottomEdge) - && !aUpdateMaximumWidth) { + if (mLines.front() != aLine && + newY > aState.mBottomEdge && + aState.mBottomEdge != NS_UNCONSTRAINEDSIZE && + !aUpdateMaximumWidth) { // Push this line and all of it's children and anything else that // follows to our next-in-flow NS_ASSERTION((aState.mCurrentLine == aLine), "oops");