Make sure that first-lines with descendant views will be flagged appropriately.

Bug 291078, r+sr=roc
This commit is contained in:
bzbarsky%mit.edu 2006-11-13 21:46:12 +00:00
parent 701b361f78
commit 0b0dc9004f

View File

@ -11656,6 +11656,15 @@ ReparentFrame(nsFrameManager* aFrameManager,
{
aFrame->SetParent(aNewParentFrame);
aFrameManager->ReParentStyleContext(aFrame);
if (aFrame->GetStateBits() &
(NS_FRAME_HAS_VIEW | NS_FRAME_HAS_CHILD_WITH_VIEW)) {
// No need to walk up the tree, since the bits are already set
// right on the parent of aNewParentFrame.
NS_ASSERTION(aNewParentFrame->GetParent()->GetStateBits() &
NS_FRAME_HAS_CHILD_WITH_VIEW,
"aNewParentFrame's parent should have this bit set!");
aNewParentFrame->AddStateBits(NS_FRAME_HAS_CHILD_WITH_VIEW);
}
}
// Special routine to handle placing a list of frames into a block