Use ParseSingleValueProperty for the components inside the 'transition' shorthand as well. (Bug 636029) r=bzbarsky

This commit is contained in:
L. David Baron 2011-03-05 09:58:33 -08:00
parent 7d588db662
commit 0c50a7e668
2 changed files with 2 additions and 17 deletions

View File

@ -8098,22 +8098,7 @@ CSSParserImpl::ParseTransition()
// if we haven't found this property yet, try to parse it
PRInt32 variantMask;
const PRInt32* table = nsnull;
switch (kTransitionProperties[i]) {
case eCSSProperty_transition_property:
variantMask = VARIANT_IDENTIFIER | VARIANT_NONE | VARIANT_ALL;
break;
case eCSSProperty_transition_duration:
case eCSSProperty_transition_delay:
variantMask = VARIANT_TIME;
break;
case eCSSProperty_transition_timing_function:
variantMask = VARIANT_TIMING_FUNCTION;
table = nsCSSProps::kTransitionTimingFunctionKTable;
break;
default:
NS_ABORT_IF_FALSE(PR_FALSE, "Invalid transition property");
}
if (ParseVariant(tempValue, variantMask, table)) {
if (ParseSingleValueProperty(tempValue, kTransitionProperties[i])) {
parsedProperty[i] = PR_TRUE;
cur[i] = AppendValueToList(values[i], cur[i], tempValue);
foundProperty = PR_TRUE;

View File

@ -2598,7 +2598,7 @@ CSS_PROP_DISPLAY(
CSS_PROPERTY_VALUE_LIST_USES_COMMAS,
Display,
mTransitionProperty,
0,
VARIANT_IDENTIFIER | VARIANT_NONE | VARIANT_ALL, // used only in shorthand
nsnull,
CSS_PROP_NO_OFFSET,
eStyleAnimType_None)