Bug 847209 - Don't assert if the frame is in the kOverflowList child list. r=bzbarsky

This commit is contained in:
Mats Palmgren 2013-03-15 23:32:35 +01:00
parent 30b8a9aadc
commit 596e206f74
3 changed files with 26 additions and 6 deletions

View File

@ -0,0 +1,16 @@
<!DOCTYPE html>
<html>
<head>
<style>
.f:first-letter {
float: left;
}
.f {
page-break-inside: avoid;
}
</style>
</head>
<body onload="document.getElementById('p').className = '';">
<p id="p" class="f">text</p>
</body>
</html>

View File

@ -451,3 +451,4 @@ load 842132-1.html
test-pref(layout.css.flexbox.enabled,true) load 844529-1.html
load 847130.xhtml
load 847208.html
asserts(4) load 847209.html # bug 847368

View File

@ -1240,14 +1240,17 @@ nsContainerFrame::StealFrame(nsPresContext* aPresContext,
{
#ifdef DEBUG
if (!mFrames.ContainsFrame(aChild)) {
FramePropertyTable* propTable = aPresContext->PropertyTable();
nsFrameList* list = static_cast<nsFrameList*>(
propTable->Get(this, OverflowContainersProperty()));
nsFrameList* list = GetOverflowFrames();
if (!list || !list->ContainsFrame(aChild)) {
FramePropertyTable* propTable = aPresContext->PropertyTable();
list = static_cast<nsFrameList*>(
propTable->Get(this, ExcessOverflowContainersProperty()));
MOZ_ASSERT(list && list->ContainsFrame(aChild), "aChild is not our child "
"or on a frame list not supported by StealFrame");
propTable->Get(this, OverflowContainersProperty()));
if (!list || !list->ContainsFrame(aChild)) {
list = static_cast<nsFrameList*>(
propTable->Get(this, ExcessOverflowContainersProperty()));
MOZ_ASSERT(list && list->ContainsFrame(aChild), "aChild isn't our child"
" or on a frame list not supported by StealFrame");
}
}
}
#endif