Require animation-duration and transtion-duration to be nonnegative at parse time. (Bug 773102, patch 3) r=bzbarsky

I believe there's some other code removal that can be done as a followup
to this patch, but that doesn't have to be done now.
This commit is contained in:
L. David Baron 2012-07-13 15:06:50 -07:00
parent ebd9a1a4a9
commit 50635ce7be
2 changed files with 6 additions and 6 deletions

View File

@ -382,7 +382,7 @@ CSS_PROP_DISPLAY(
CSS_PROPERTY_PARSE_VALUE_LIST |
CSS_PROPERTY_VALUE_LIST_USES_COMMAS,
"",
VARIANT_TIME, // used by list parsing
VARIANT_TIME | VARIANT_NONNEGATIVE_DIMENSION, // used by list parsing
nsnull,
CSS_PROP_NO_OFFSET,
eStyleAnimType_None)
@ -2689,7 +2689,7 @@ CSS_PROP_DISPLAY(
CSS_PROPERTY_PARSE_VALUE_LIST |
CSS_PROPERTY_VALUE_LIST_USES_COMMAS,
"",
VARIANT_TIME, // used by list parsing
VARIANT_TIME | VARIANT_NONNEGATIVE_DIMENSION, // used by list parsing
nsnull,
CSS_PROP_NO_OFFSET,
eStyleAnimType_None)

View File

@ -73,8 +73,8 @@ var gCSSProperties = {
inherited: false,
type: CSS_TYPE_LONGHAND,
initial_values: [ "0s", "0ms" ],
other_values: [ "1s", "250ms", "-1ms", "-2s", "1s, 250ms, 2.3s"],
invalid_values: [ "0", "0px" ]
other_values: [ "1s", "250ms", "1s, 250ms, 2.3s"],
invalid_values: [ "0", "0px", "-1ms", "-2s" ]
},
"animation-fill-mode": {
domProp: "animationFillMode",
@ -3310,8 +3310,8 @@ var gCSSProperties = {
inherited: false,
type: CSS_TYPE_LONGHAND,
initial_values: [ "0s", "0ms" ],
other_values: [ "1s", "250ms", "-1ms", "-2s", "1s, 250ms, 2.3s"],
invalid_values: [ "0", "0px" ]
other_values: [ "1s", "250ms", "1s, 250ms, 2.3s"],
invalid_values: [ "0", "0px", "-1ms", "-2s" ]
},
"transition-property": {
domProp: "transitionProperty",