Bug 579323. Part 3: Fix invalidation of lines to update layers as necessary. r=dbaron

--HG--
extra : rebase_source : 6a043bda5f16f9a257fa4bfa272d8362facef4c2
This commit is contained in:
Robert O'Callahan 2010-08-31 12:49:13 +12:00
parent c7acef03ff
commit 3815d31b6e

View File

@ -88,6 +88,7 @@
#include "nsCSSAnonBoxes.h"
#include "nsCSSFrameConstructor.h"
#include "nsCSSRendering.h"
#include "FrameLayerBuilder.h"
#ifdef IBMBIDI
#include "nsBidiPresUtils.h"
@ -2459,6 +2460,7 @@ nsBlockFrame::ReflowLine(nsBlockReflowState& aState,
this, dirtyRect.x, dirtyRect.y, dirtyRect.width, dirtyRect.height);
#endif
Invalidate(dirtyRect);
FrameLayerBuilder::InvalidateThebesLayersInSubtree(aLine->mFirstChild);
} else {
nsRect combinedAreaHStrip, combinedAreaVStrip;
nsRect boundsHStrip, boundsVStrip;
@ -2503,6 +2505,13 @@ nsBlockFrame::ReflowLine(nsBlockReflowState& aState,
printf(" dirty line is %p\n", static_cast<void*>(aLine.get());
#endif
Invalidate(dirtyRect);
if (GetStateBits() & NS_FRAME_HAS_CONTAINER_LAYER_DESCENDANT) {
PRInt32 childCount = aLine->GetChildCount();
for (nsIFrame* f = aLine->mFirstChild; childCount;
--childCount, f = f->GetNextSibling()) {
FrameLayerBuilder::InvalidateThebesLayersInSubtree(f);
}
}
}
return rv;