if ((val < 0) || ((0 == val) && mInner.InNavQuirksMode())) {
if ((val < 0) || ((0 == val) && mInner.InNavQuirksMode(mInner.mDocument))) {
nsHTMLTableCellElement::StringToAttribute(nsIAtom* aAttribute,                                   const nsString& aValue,                                   nsHTMLValue& aResult){  /* ignore these attributes, stored simply as strings     abbr, axis, ch, headers   */  /* attributes that resolve to integers with a min of 0 */  if (aAttribute == nsHTMLAtoms::choff) {    if (nsGenericHTMLElement::ParseValue(aValue, 0, aResult, eHTMLUnit_Integer)) {      return NS_CONTENT_ATTR_HAS_VALUE;    }  }  else if ((aAttribute == nsHTMLAtoms::colspan) ||           (aAttribute == nsHTMLAtoms::rowspan)) {    if (nsGenericHTMLElement::ParseValue(aValue, -1, MAX_COLSPAN, aResult, eHTMLUnit_Integer)) {      PRInt32 val = aResult.GetIntValue();      // quirks mode does not honor the special html 4 value of 0      if ((val < 0) || ((0 == val) && mInner.InNavQuirksMode())) {        nsHTMLUnit unit = aResult.GetUnit();        aResult.SetIntValue(1, unit);      }      return NS_CONTENT_ATTR_HAS_VALUE;    }  }  /* attributes that resolve to integers or percents */  else if (aAttribute == nsHTMLAtoms::height) {    if (nsGenericHTMLElement::ParseValueOrPercent(aValue, aResult, eHTMLUnit_Pixel)) {      return NS_CONTENT_ATTR_HAS_VALUE;    }  }  /* attributes that resolve to integers or percents or proportions */  else if (aAttribute == nsHTMLAtoms::width) {    if (nsGenericHTMLElement::ParseValueOrPercentOrProportional(aValue, aResult, eHTMLUnit_Pixel)) {      return NS_CONTENT_ATTR_HAS_VALUE;    }  }    /* other attributes */  else if (aAttribute == nsHTMLAtoms::align) {    if (mInner.ParseTableCellHAlignValue(aValue, aResult)) {      return NS_CONTENT_ATTR_HAS_VALUE;    }  }  else if (aAttribute == nsHTMLAtoms::bgcolor) {    if (nsGenericHTMLElement::ParseColor(aValue, mInner.mDocument, aResult)) {      return NS_CONTENT_ATTR_HAS_VALUE;    }  }  else if (aAttribute == nsHTMLAtoms::scope) {    if (nsGenericHTMLElement::ParseEnumValue(aValue, kCellScopeTable, aResult)) {      return NS_CONTENT_ATTR_HAS_VALUE;    }  }  else if (aAttribute == nsHTMLAtoms::valign) {    if (nsGenericHTMLElement::ParseTableVAlignValue(aValue, aResult)) {      return NS_CONTENT_ATTR_HAS_VALUE;    }  }  return NS_CONTENT_ATTR_NOT_THERE;}