Bug 437565: In space manager, broaden the conditions under which we clear cached pointer before deleting a bandrect. r=dbaron a=ss
git-svn-id: svn://10.0.0.236/trunk@258046 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
parent
c2770b5338
commit
fa4bd491ee
@ -970,10 +970,11 @@ nsSpaceManager::RemoveRegion(nsIFrame* aFrame)
|
||||
} else {
|
||||
band = nsnull;
|
||||
}
|
||||
if (mCachedBandPosition == rect) {
|
||||
SetCachedBandPosition(band);
|
||||
}
|
||||
}
|
||||
if (mCachedBandPosition == rect) {
|
||||
// Clear cached reference to this rect before we delete it.
|
||||
SetCachedBandPosition(band);
|
||||
}
|
||||
delete rect;
|
||||
rect = next;
|
||||
|
||||
@ -995,9 +996,10 @@ nsSpaceManager::RemoveRegion(nsIFrame* aFrame)
|
||||
if (prevRect == band) {
|
||||
// the rect we're deleting is the start of the band
|
||||
band = rect;
|
||||
if (mCachedBandPosition == prevRect) {
|
||||
SetCachedBandPosition(band);
|
||||
}
|
||||
}
|
||||
if (mCachedBandPosition == prevRect) {
|
||||
// Clear cached reference to this rect before we delete it.
|
||||
SetCachedBandPosition(band);
|
||||
}
|
||||
delete prevRect;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user