зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1153695 - Wrap nsAutoOOFFrameList in a scope to ensure its dtor runs before the VerifyOverflowSituation() call (to avoid frames appearing to be on two child lists). r=roc
This commit is contained in:
Родитель
313a973bc0
Коммит
6e7818f946
|
@ -4713,18 +4713,20 @@ nsBlockFrame::DrainSelfOverflowList()
|
|||
|
||||
// No need to reparent frames in our own overflow lines/oofs, because they're
|
||||
// already ours. But we should put overflow floats back in mFloats.
|
||||
nsAutoOOFFrameList oofs(this);
|
||||
if (oofs.mList.NotEmpty()) {
|
||||
// (explicit scope to remove the OOF list before VerifyOverflowSituation)
|
||||
{
|
||||
nsAutoOOFFrameList oofs(this);
|
||||
if (oofs.mList.NotEmpty()) {
|
||||
#ifdef DEBUG
|
||||
for (nsIFrame* f : oofs.mList) {
|
||||
MOZ_ASSERT(!(f->GetStateBits() & NS_FRAME_IS_PUSHED_FLOAT),
|
||||
"CollectFloats should've removed that bit");
|
||||
}
|
||||
for (nsIFrame* f : oofs.mList) {
|
||||
MOZ_ASSERT(!(f->GetStateBits() & NS_FRAME_IS_PUSHED_FLOAT),
|
||||
"CollectFloats should've removed that bit");
|
||||
}
|
||||
#endif
|
||||
// The overflow floats go after our regular floats.
|
||||
mFloats.AppendFrames(nullptr, oofs.mList);
|
||||
// The overflow floats go after our regular floats.
|
||||
mFloats.AppendFrames(nullptr, oofs.mList);
|
||||
}
|
||||
}
|
||||
|
||||
if (!ourOverflowLines->mLines.empty()) {
|
||||
mFrames.AppendFrames(nullptr, ourOverflowLines->mFrames);
|
||||
mLines.splice(mLines.end(), ourOverflowLines->mLines);
|
||||
|
|
Загрузка…
Ссылка в новой задаче