(tableSpecifiedHeight > 0))
(tableSpecifiedHeight > 0) && eCompatibility_NavQuirks != GetPresContext()->CompatibilityMode())
nsTableFrame::CalcDesiredHeight(const nsHTMLReflowState& aReflowState) {  nsTableCellMap* cellMap = GetCellMap();  if (!cellMap) {    NS_ASSERTION(PR_FALSE, "never ever call me until the cell map is built!");    return 0;  }  nscoord  cellSpacingY = GetCellSpacingY();  nsMargin borderPadding = GetChildAreaOffset(&aReflowState);  // get the natural height based on the last child's (row group or scroll frame) rect  nsAutoVoidArray rowGroups;  PRUint32 numRowGroups;  OrderRowGroups(rowGroups, numRowGroups, nsnull);  if (numRowGroups <= 0) {    // tables can be used as rectangular items without content    nscoord tableSpecifiedHeight = CalcBorderBoxHeight(aReflowState);    if ((NS_UNCONSTRAINEDSIZE != tableSpecifiedHeight) &&        (tableSpecifiedHeight > 0))      return tableSpecifiedHeight;    return 0;  }  nscoord desiredHeight = borderPadding.top + cellSpacingY + borderPadding.bottom;  for (PRUint32 rgX = 0; rgX < numRowGroups; rgX++) {    nsIFrame* rg = (nsIFrame*)rowGroups.ElementAt(rgX);    if (rg) {      desiredHeight += rg->GetSize().height + cellSpacingY;    }  }  // see if a specified table height requires dividing additional space to rows  if (!mPrevInFlow) {    nscoord tableSpecifiedHeight = CalcBorderBoxHeight(aReflowState);    if ((tableSpecifiedHeight > 0) &&         (tableSpecifiedHeight != NS_UNCONSTRAINEDSIZE) &&        (tableSpecifiedHeight > desiredHeight)) {      // proportionately distribute the excess height to unconstrained rows in each      // unconstrained row group.We don't need to do this if it's an unconstrained reflow      if (NS_UNCONSTRAINEDSIZE != aReflowState.availableWidth) {         DistributeHeightToRows(aReflowState, tableSpecifiedHeight - desiredHeight);      }      desiredHeight = tableSpecifiedHeight;    }  }  return desiredHeight;}