Verify that mIsBlock is correct

git-svn-id: svn://10.0.0.236/trunk@3274 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
kipp
1998-06-04 23:10:15 +00:00
parent e8ee07264a
commit 06c374c6f3
2 changed files with 26 additions and 0 deletions

View File

@@ -108,6 +108,19 @@ nsLineData::Verify(PRBool aFinalCheck) const
NS_ASSERTION(len == mChildCount, "bad child count");
}
if (1 == mChildCount) {
if (mIsBlock) {
nsIFrame* child = mFirstChild;
nsIStyleContext* sc;
child->GetStyleContext(nsnull, sc);
nsStyleDisplay* display = (nsStyleDisplay*)
sc->GetData(eStyleStruct_Display);
NS_ASSERTION((NS_STYLE_DISPLAY_BLOCK == display->mDisplay) ||
(NS_STYLE_DISPLAY_LIST_ITEM == display->mDisplay),
"bad mIsBlock state");
}
}
// XXX verify content offsets and mLastContentIsComplete
return NS_OK;
}