From 43a8b27bb7c415f7970d1cb5021e1b51efb5d05a Mon Sep 17 00:00:00 2001 From: "mats.palmgren@bredband.net" Date: Tue, 22 Aug 2006 03:04:18 +0000 Subject: [PATCH] Don't steal floats from descendant float containing blocks. b=348887 r+sr=roc --- layout/generic/nsBlockFrame.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/layout/generic/nsBlockFrame.cpp b/layout/generic/nsBlockFrame.cpp index 7263fdae2499..42e86b89e14e 100644 --- a/layout/generic/nsBlockFrame.cpp +++ b/layout/generic/nsBlockFrame.cpp @@ -7135,13 +7135,13 @@ nsBlockFrame::ReflowBullet(nsBlockReflowState& aState, // This is used to scan frames for any float placeholders, add their // floats to the list represented by aHead and aTail, and remove the -// floats from whatever list they might be in. We only search the -// inline descendants. The floats must be children of 'this'. +// floats from whatever list they might be in. We don't search descendants +// that are float containing blocks. The floats must be children of 'this'. void nsBlockFrame::CollectFloats(nsIFrame* aFrame, nsFrameList& aList, nsIFrame** aTail, PRBool aFromOverflow) { while (aFrame) { - // Don't descend into block children - if (!aFrame->GetStyleDisplay()->IsBlockLevel()) { + // Don't descend into float containing blocks. + if (!aFrame->IsFloatContainingBlock()) { nsIFrame *outOfFlowFrame = nsLayoutUtils::GetFloatFromPlaceholder(aFrame); if (outOfFlowFrame) { // Make sure that its parent is us. Otherwise we don't want