CSS properties set to system colors were returning inconsistent values; b=172199, r=caillon, sr=peterv
git-svn-id: svn://10.0.0.236/trunk@133139 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -4859,7 +4859,13 @@ PRBool nsCSSDeclaration::AppendValueToString(nsCSSProperty aProperty, const nsCS
|
||||
else if (eCSSUnit_Integer == unit) {
|
||||
switch (aProperty) {
|
||||
case eCSSProperty_color:
|
||||
case eCSSProperty_background_color: {
|
||||
case eCSSProperty_background_color:
|
||||
case eCSSProperty_border_top_color:
|
||||
case eCSSProperty_border_bottom_color:
|
||||
case eCSSProperty_border_left_color:
|
||||
case eCSSProperty_border_right_color:
|
||||
case eCSSProperty__moz_outline_color:
|
||||
case eCSSProperty_text_shadow_color: {
|
||||
// we can lookup the property in the ColorTable and then
|
||||
// get a string mapping the name
|
||||
nsAutoString tmpStr;
|
||||
@@ -5378,6 +5384,32 @@ nsCSSDeclaration::GetValue(nsCSSProperty aProperty,
|
||||
}
|
||||
break;
|
||||
}
|
||||
case eCSSProperty_border_top_colors:
|
||||
case eCSSProperty_border_right_colors:
|
||||
case eCSSProperty_border_bottom_colors:
|
||||
case eCSSProperty_border_left_colors: {
|
||||
CSS_VARONSTACK_GET(Margin);
|
||||
PRUint8 index;
|
||||
switch (aProperty) {
|
||||
case eCSSProperty_border_top_colors: index = 0; break;
|
||||
case eCSSProperty_border_right_colors: index = 1; break;
|
||||
case eCSSProperty_border_bottom_colors: index = 2; break;
|
||||
case eCSSProperty_border_left_colors: index = 3; break;
|
||||
CSS_BOGUS_DEFAULT; // make compiler happy
|
||||
}
|
||||
if ((nsnull != theMargin) && (nsnull != theMargin->mBorderColors) &&
|
||||
(nsnull != theMargin->mBorderColors[index])) {
|
||||
nsCSSValueList* borderSideColors = theMargin->mBorderColors[index];
|
||||
do {
|
||||
AppendValueToString(aProperty, borderSideColors->mValue, aValue);
|
||||
borderSideColors = borderSideColors->mNext;
|
||||
if (nsnull != borderSideColors) {
|
||||
aValue.Append(PRUnichar(' '));
|
||||
}
|
||||
} while (nsnull != borderSideColors);
|
||||
}
|
||||
break;
|
||||
}
|
||||
default:
|
||||
AppendValueToString(aProperty, aValue);
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user