Bug 422678. Table rows whose style-height doesn't fit in the available height (but whose cells do) should be marked incomplete during reflow. r=bernd,sr=dbaron

This commit is contained in:
2008-04-08 05:28:34 -07:00
parent 162f97a08d
commit 472fb39b55
9 changed files with 214 additions and 9 deletions

View File

@@ -911,7 +911,19 @@ NS_METHOD nsTableCellFrame::Reflow(nsPresContext* aPresContext,
// 0 dimensioned cells need to be treated specially in Standard/NavQuirks mode
// see testcase "emptyCells.html"
SetContentEmpty(0 == kidSize.height);
nsIFrame* prevInFlow = GetPrevInFlow();
PRBool isEmpty;
if (prevInFlow) {
isEmpty = static_cast<nsTableCellFrame*>(prevInFlow)->GetContentEmpty();
} else {
// XXX this is a bad way to check for empty content. There are various
// ways the cell could have content but the kid could end up with zero
// height. See
// http://www.w3.org/TR/CSS21/tables.html#empty-cells
// and bug 76331.
isEmpty = kidSize.height == 0;
}
SetContentEmpty(isEmpty);
// Place the child
FinishReflowChild(firstKid, aPresContext, &kidReflowState, kidSize,