Bug 559834 - Remove support for table@align=abscenter/absmiddle/middle. r=jst

This commit is contained in:
Ms2ger@gmail.com 2010-06-11 20:47:56 +02:00
parent 1c4766585c
commit 91e11b4fc1
2 changed files with 3 additions and 20 deletions

View File

@ -1516,7 +1516,6 @@ nsGenericHTMLElement::ParseAlignValue(const nsAString& aString,
//----------------------------------------
// Vanilla table as defined by the html4 spec...
static const nsAttrValue::EnumTable kTableHAlignTable[] = {
{ "left", NS_STYLE_TEXT_ALIGN_LEFT },
{ "right", NS_STYLE_TEXT_ALIGN_RIGHT },
@ -1526,26 +1525,10 @@ static const nsAttrValue::EnumTable kTableHAlignTable[] = {
{ 0 }
};
// This table is used for TABLE when in compatability mode
static const nsAttrValue::EnumTable kCompatTableHAlignTable[] = {
{ "left", NS_STYLE_TEXT_ALIGN_LEFT },
{ "right", NS_STYLE_TEXT_ALIGN_RIGHT },
{ "center", NS_STYLE_TEXT_ALIGN_CENTER },
{ "char", NS_STYLE_TEXT_ALIGN_CHAR },
{ "justify",NS_STYLE_TEXT_ALIGN_JUSTIFY },
{ "abscenter", NS_STYLE_TEXT_ALIGN_CENTER },
{ "absmiddle", NS_STYLE_TEXT_ALIGN_CENTER },
{ "middle", NS_STYLE_TEXT_ALIGN_CENTER },
{ 0 }
};
PRBool
nsGenericHTMLElement::ParseTableHAlignValue(const nsAString& aString,
nsAttrValue& aResult) const
nsAttrValue& aResult)
{
if (InNavQuirksMode(GetOwnerDoc())) {
return aResult.ParseEnumValue(aString, kCompatTableHAlignTable, PR_FALSE);
}
return aResult.ParseEnumValue(aString, kTableHAlignTable, PR_FALSE);
}

View File

@ -264,8 +264,8 @@ public:
* @param aResult the resulting HTMLValue
* @return whether the value was parsed
*/
PRBool ParseTableHAlignValue(const nsAString& aString,
nsAttrValue& aResult) const;
static PRBool ParseTableHAlignValue(const nsAString& aString,
nsAttrValue& aResult);
/**
* Convert a table cell halign string to value