Title: [176050] trunk
Revision
176050
Author
[email protected]
Date
2014-11-12 17:23:15 -0800 (Wed, 12 Nov 2014)

Log Message

Support unprefixed animation property names
https://bugs.webkit.org/show_bug.cgi?id=138678
<rdar://problem/18943059>

Reviewed by Simon Fraser.

Source/WebCore:

Step 1 of 3 in unprefixing CSS animations: handling the
property names and values.

Unlike other unprefixing, where we use an alias that
effectively removes the prefixed values from the code,
for animations we need to keep the old values around so that
existing content will not break (e.g. computed style).

During testing I noticed that we didn't handle the
(relatively) new animation-direction values of
"reverse" and "alternate-reverse" when querying
computed style.

Tests: animations/unprefixed-properties.html
       animations/unprefixed-shorthand.html

* css/CSSComputedStyleDeclaration.cpp:
(WebCore::ComputedStyleExtractor::propertyValue): Handle the unprefixed
values, but also get animation direction to produce the correct
results when "reverse" and "alternate-reverse" is specified.

* css/CSSParser.cpp: Handle the new values. If necessary, pass a flag
around indicating whether it is prefixed or unprefixed.
(WebCore::CSSParser::parseValue):
(WebCore::CSSParser::parseAnimationShorthand): Use the flag to decide
which of the forms we're going to check.
(WebCore::CSSParser::parseAnimationProperty):
* css/CSSParser.h:

* css/CSSProperty.h:
(WebCore::prefixingVariantForPropertyId): Add prefixing/unprefixing variants for
all the animation values, and clean up the code a bit.

* css/CSSPropertyNames.in: Add new properties.

* css/DeprecatedStyleBuilder.cpp:
(WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder): We need handlers for the
unprefixed forms. This should move to the new StyleBuilder soon.

* css/StyleProperties.cpp: Handle new values.
(WebCore::StyleProperties::getPropertyValue):
(WebCore::StyleProperties::asText):

* css/StylePropertyShorthand.cpp:
(WebCore::animationShorthand):
(WebCore::animationShorthandForParsing): Decide which list of properties to use.
(WebCore::shorthandForProperty):
(WebCore::matchingShorthandsForLonghand):
(WebCore::webkitAnimationShorthandForParsing): Deleted.
* css/StylePropertyShorthand.h:

* css/StyleResolver.cpp: Since the new properties come before "background" in
alphabetical order, they are earlier in the CSSPropertyNames.in file, and thus
we need to update the call sites that think CSSPropertyBackground is the first
property.
(WebCore::StyleResolver::styleForKeyframe): Replace CSSPropertyBackground with CSSPropertyAnimation.
(WebCore::StyleResolver::styleForPage):
(WebCore::StyleResolver::applyMatchedProperties):
(WebCore::StyleResolver::applyProperty):

LayoutTests:

Tests for unprefixed parsing and calculation of animation
properties. Fun fact, this is the first test we have
for the computed style of all animation-direction values.

* animations/unprefixed-properties-expected.txt: Added.
* animations/unprefixed-properties.html: Added.
* animations/unprefixed-shorthand-expected.txt: Added.
* animations/unprefixed-shorthand.html: Added.

Modified Paths

Added Paths

Diff

Modified: trunk/LayoutTests/ChangeLog (176049 => 176050)


--- trunk/LayoutTests/ChangeLog	2014-11-13 00:27:17 UTC (rev 176049)
+++ trunk/LayoutTests/ChangeLog	2014-11-13 01:23:15 UTC (rev 176050)
@@ -1,3 +1,20 @@
+2014-11-12  Dean Jackson  <[email protected]>
+
+        Support unprefixed animation property names
+        https://bugs.webkit.org/show_bug.cgi?id=138678
+        <rdar://problem/18943059>
+
+        Reviewed by Simon Fraser.
+
+        Tests for unprefixed parsing and calculation of animation
+        properties. Fun fact, this is the first test we have
+        for the computed style of all animation-direction values.
+
+        * animations/unprefixed-properties-expected.txt: Added.
+        * animations/unprefixed-properties.html: Added.
+        * animations/unprefixed-shorthand-expected.txt: Added.
+        * animations/unprefixed-shorthand.html: Added.
+
 2014-11-12  Alexey Proskuryakov  <[email protected]>
 
         <rdar://problem/15864185> Syrah: platform/mac/editing/attributed-string tests are failing

Added: trunk/LayoutTests/animations/unprefixed-properties-expected.txt (0 => 176050)


--- trunk/LayoutTests/animations/unprefixed-properties-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/animations/unprefixed-properties-expected.txt	2014-11-13 01:23:15 UTC (rev 176050)
@@ -0,0 +1,296 @@
+Test the unprefixed animation properties.
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+
+Parsing - Basic animation-name : waldo
+PASS cssRule.type is 1
+PASS declaration.length is 2
+PASS declaration.getPropertyValue('animation-name') is 'waldo'
+PASS declaration.getPropertyValue('-webkit-animation-name') is 'waldo'
+
+Parsing - Multiple animation-names : waldo, wally
+PASS cssRule.type is 1
+PASS declaration.length is 2
+PASS declaration.getPropertyValue('animation-name') is 'waldo, wally'
+PASS declaration.getPropertyValue('-webkit-animation-name') is 'waldo, wally'
+PASS subRule.cssText is 'waldo'
+PASS subRule.cssText is 'wally'
+
+Parsing - Basic animation-duration : 5s
+PASS cssRule.type is 1
+PASS declaration.length is 2
+PASS declaration.getPropertyValue('animation-duration') is '5s'
+PASS declaration.getPropertyValue('-webkit-animation-duration') is '5s'
+
+Parsing - Multiple animation-durations : 10s, 20ms
+PASS cssRule.type is 1
+PASS declaration.length is 2
+PASS declaration.getPropertyValue('animation-duration') is '10s, 20ms'
+PASS declaration.getPropertyValue('-webkit-animation-duration') is '10s, 20ms'
+PASS subRule.cssText is '10s'
+PASS subRule.cssText is '20ms'
+
+Parsing - Basic animation-delay : 5s
+PASS cssRule.type is 1
+PASS declaration.length is 2
+PASS declaration.getPropertyValue('animation-delay') is '5s'
+PASS declaration.getPropertyValue('-webkit-animation-delay') is '5s'
+
+Parsing - Multiple animation-delays : 10s, 20ms
+PASS cssRule.type is 1
+PASS declaration.length is 2
+PASS declaration.getPropertyValue('animation-delay') is '10s, 20ms'
+PASS declaration.getPropertyValue('-webkit-animation-delay') is '10s, 20ms'
+PASS subRule.cssText is '10s'
+PASS subRule.cssText is '20ms'
+
+Parsing - Basic animation-timing-function : ease-in-out
+PASS cssRule.type is 1
+PASS declaration.length is 2
+PASS declaration.getPropertyValue('animation-timing-function') is 'ease-in-out'
+PASS declaration.getPropertyValue('-webkit-animation-timing-function') is 'ease-in-out'
+
+Parsing - animation-timing-function with bezier : cubic-bezier(0.2, 0.3, 0.4, 0.5)
+PASS cssRule.type is 1
+PASS declaration.length is 2
+PASS declaration.getPropertyValue('animation-timing-function') is 'cubic-bezier(0.2, 0.3, 0.4, 0.5)'
+PASS declaration.getPropertyValue('-webkit-animation-timing-function') is 'cubic-bezier(0.2, 0.3, 0.4, 0.5)'
+
+Parsing - Multiple animation-timing-functions : ease-in, ease-out
+PASS cssRule.type is 1
+PASS declaration.length is 2
+PASS declaration.getPropertyValue('animation-timing-function') is 'ease-in, ease-out'
+PASS declaration.getPropertyValue('-webkit-animation-timing-function') is 'ease-in, ease-out'
+PASS subRule.cssText is 'ease-in'
+PASS subRule.cssText is 'ease-out'
+
+Parsing - Basic animation-iteration-count : 4
+PASS cssRule.type is 1
+PASS declaration.length is 2
+PASS declaration.getPropertyValue('animation-iteration-count') is '4'
+PASS declaration.getPropertyValue('-webkit-animation-iteration-count') is '4'
+
+Parsing - animation-iteration-count with keyword : infinite
+PASS cssRule.type is 1
+PASS declaration.length is 2
+PASS declaration.getPropertyValue('animation-iteration-count') is 'infinite'
+PASS declaration.getPropertyValue('-webkit-animation-iteration-count') is 'infinite'
+
+Parsing - Multiple animation-iteration-counts : 2, infinite, 4
+PASS cssRule.type is 1
+PASS declaration.length is 2
+PASS declaration.getPropertyValue('animation-iteration-count') is '2, infinite, 4'
+PASS declaration.getPropertyValue('-webkit-animation-iteration-count') is '2, infinite, 4'
+PASS subRule.cssText is '2'
+PASS subRule.cssText is 'infinite'
+PASS subRule.cssText is '4'
+
+Parsing - Normal animation-direction : normal
+PASS cssRule.type is 1
+PASS declaration.length is 2
+PASS declaration.getPropertyValue('animation-direction') is 'normal'
+PASS declaration.getPropertyValue('-webkit-animation-direction') is 'normal'
+
+Parsing - Alternate animation-direction : alternate
+PASS cssRule.type is 1
+PASS declaration.length is 2
+PASS declaration.getPropertyValue('animation-direction') is 'alternate'
+PASS declaration.getPropertyValue('-webkit-animation-direction') is 'alternate'
+
+Parsing - Reverse animation-direction : reverse
+PASS cssRule.type is 1
+PASS declaration.length is 2
+PASS declaration.getPropertyValue('animation-direction') is 'reverse'
+PASS declaration.getPropertyValue('-webkit-animation-direction') is 'reverse'
+
+Parsing - Alternate Reverse animation-direction : alternate-reverse
+PASS cssRule.type is 1
+PASS declaration.length is 2
+PASS declaration.getPropertyValue('animation-direction') is 'alternate-reverse'
+PASS declaration.getPropertyValue('-webkit-animation-direction') is 'alternate-reverse'
+
+Parsing - Multiple animation-directions : alternate, alternate, normal
+PASS cssRule.type is 1
+PASS declaration.length is 2
+PASS declaration.getPropertyValue('animation-direction') is 'alternate, alternate, normal'
+PASS declaration.getPropertyValue('-webkit-animation-direction') is 'alternate, alternate, normal'
+PASS subRule.cssText is 'alternate'
+PASS subRule.cssText is 'alternate'
+PASS subRule.cssText is 'normal'
+
+Parsing - None animation-fill-mode : none
+PASS cssRule.type is 1
+PASS declaration.length is 2
+PASS declaration.getPropertyValue('animation-fill-mode') is 'none'
+PASS declaration.getPropertyValue('-webkit-animation-fill-mode') is 'none'
+
+Parsing - Forwards animation-fill-mode : forwards
+PASS cssRule.type is 1
+PASS declaration.length is 2
+PASS declaration.getPropertyValue('animation-fill-mode') is 'forwards'
+PASS declaration.getPropertyValue('-webkit-animation-fill-mode') is 'forwards'
+
+Parsing - Backwards animation-fill-mode : backwards
+PASS cssRule.type is 1
+PASS declaration.length is 2
+PASS declaration.getPropertyValue('animation-fill-mode') is 'backwards'
+PASS declaration.getPropertyValue('-webkit-animation-fill-mode') is 'backwards'
+
+Parsing - Both animation-fill-mode : both
+PASS cssRule.type is 1
+PASS declaration.length is 2
+PASS declaration.getPropertyValue('animation-fill-mode') is 'both'
+PASS declaration.getPropertyValue('-webkit-animation-fill-mode') is 'both'
+
+Parsing - Multiple animation-fill-modes : none, forwards, backwards, both
+PASS cssRule.type is 1
+PASS declaration.length is 2
+PASS declaration.getPropertyValue('animation-fill-mode') is 'none, forwards, backwards, both'
+PASS declaration.getPropertyValue('-webkit-animation-fill-mode') is 'none, forwards, backwards, both'
+PASS subRule.cssText is 'none'
+PASS subRule.cssText is 'forwards'
+PASS subRule.cssText is 'backwards'
+PASS subRule.cssText is 'both'
+
+Invalid - duration - Bad value : 10cm
+PASS cssRule.type is 1
+PASS declaration.length is 0
+PASS declaration.getPropertyValue('animation-duration') is null
+
+Invalid - duration - List with bad value : 10ms, 10cm, 10s
+PASS cssRule.type is 1
+PASS declaration.length is 0
+PASS declaration.getPropertyValue('animation-duration') is null
+
+Invalid - delay - Bad value : 10cm
+PASS cssRule.type is 1
+PASS declaration.length is 0
+PASS declaration.getPropertyValue('animation-delay') is null
+
+Invalid - delay - List with bad value : 10ms, 10cm, 10s
+PASS cssRule.type is 1
+PASS declaration.length is 0
+PASS declaration.getPropertyValue('animation-delay') is null
+
+Invalid - timing-function - Wrong keyword parameter : egg
+PASS cssRule.type is 1
+PASS declaration.length is 0
+PASS declaration.getPropertyValue('animation-timing-function') is null
+
+Invalid - timing-function - List with wrong keyword parameter : ease-in, egg, ease-out
+PASS cssRule.type is 1
+PASS declaration.length is 0
+PASS declaration.getPropertyValue('animation-timing-function') is null
+
+Invalid - iteration-count - Wrong keyword parameter : banana
+PASS cssRule.type is 1
+PASS declaration.length is 0
+PASS declaration.getPropertyValue('animation-iteration-count') is null
+
+Invalid - iteration-count - List with wrong keyword parameter : infinite, 10, banana
+PASS cssRule.type is 1
+PASS declaration.length is 0
+PASS declaration.getPropertyValue('animation-iteration-count') is null
+
+Invalid - direction - Wrong keyword parameter : all
+PASS cssRule.type is 1
+PASS declaration.length is 0
+PASS declaration.getPropertyValue('animation-direction') is null
+
+Invalid - direction - List with wrong keyword parameter : normal, alternate, none
+PASS cssRule.type is 1
+PASS declaration.length is 0
+PASS declaration.getPropertyValue('animation-direction') is null
+
+Invalid - fill-mode - Wrong keyword parameter : all
+PASS cssRule.type is 1
+PASS declaration.length is 0
+PASS declaration.getPropertyValue('animation-fill-mode') is null
+
+Invalid - fill-mode - List with wrong keyword parameter : none, backwards, left, alternate, forwards
+PASS cssRule.type is 1
+PASS declaration.length is 0
+PASS declaration.getPropertyValue('animation-fill-mode') is null
+
+Computed Style - Basic animation-name : waldo
+PASS animationStyle.cssText is 'waldo'
+
+Computed Style - Multiple animation-names : waldo, wally
+PASS subRule.cssText is 'waldo'
+PASS subRule.cssText is 'wally'
+
+Computed Style - Basic animation-duration : 5s
+PASS animationStyle.cssText is '5s'
+
+Computed Style - Multiple animation-durations : 10s, 20ms
+PASS subRule.cssText is '10s'
+PASS subRule.cssText is '0.02s'
+
+Computed Style - Basic animation-delay : 5s
+PASS animationStyle.cssText is '5s'
+
+Computed Style - Multiple animation-delays : 10s, 20ms
+PASS subRule.cssText is '10s'
+PASS subRule.cssText is '0.02s'
+
+Computed Style - Basic animation-timing-function : ease-in-out
+PASS animationStyle.cssText is 'ease-in-out'
+
+Computed Style - animation-timing-function with bezier : cubic-bezier(0.2, 0.3, 0.4, 0.5)
+PASS animationStyle.cssText is 'cubic-bezier(0.2, 0.3, 0.4, 0.5)'
+
+Computed Style - Multiple animation-timing-functions : ease-in, ease-out
+PASS subRule.cssText is 'ease-in'
+PASS subRule.cssText is 'ease-out'
+
+Computed Style - Basic animation-iteration-count : 4
+PASS animationStyle.cssText is '4'
+
+Computed Style - animation-iteration-count with keyword : infinite
+PASS animationStyle.cssText is 'infinite'
+
+Computed Style - Multiple animation-iteration-counts : 2, infinite, 4
+PASS subRule.cssText is '2'
+PASS subRule.cssText is 'infinite'
+PASS subRule.cssText is '4'
+
+Computed Style - Normal animation-direction : normal
+PASS animationStyle.cssText is 'normal'
+
+Computed Style - Alternate animation-direction : alternate
+PASS animationStyle.cssText is 'alternate'
+
+Computed Style - Reverse animation-direction : reverse
+PASS animationStyle.cssText is 'reverse'
+
+Computed Style - Alternate Reverse animation-direction : alternate-reverse
+PASS animationStyle.cssText is 'alternate-reverse'
+
+Computed Style - Multiple animation-directions : alternate, alternate, normal
+PASS subRule.cssText is 'alternate'
+PASS subRule.cssText is 'alternate'
+PASS subRule.cssText is 'normal'
+
+Computed Style - None animation-fill-mode : none
+PASS animationStyle.cssText is 'none'
+
+Computed Style - Forwards animation-fill-mode : forwards
+PASS animationStyle.cssText is 'forwards'
+
+Computed Style - Backwards animation-fill-mode : backwards
+PASS animationStyle.cssText is 'backwards'
+
+Computed Style - Both animation-fill-mode : both
+PASS animationStyle.cssText is 'both'
+
+Computed Style - Multiple animation-fill-modes : none, forwards, backwards, both
+PASS subRule.cssText is 'none'
+PASS subRule.cssText is 'forwards'
+PASS subRule.cssText is 'backwards'
+PASS subRule.cssText is 'both'
+PASS successfullyParsed is true
+
+TEST COMPLETE
+
Property changes on: trunk/LayoutTests/animations/unprefixed-properties-expected.txt
___________________________________________________________________

Added: svn:mime-type

Added: svn:keywords

Added: svn:eol-style

Added: trunk/LayoutTests/animations/unprefixed-properties.html (0 => 176050)


--- trunk/LayoutTests/animations/unprefixed-properties.html	                        (rev 0)
+++ trunk/LayoutTests/animations/unprefixed-properties.html	2014-11-13 01:23:15 UTC (rev 176050)
@@ -0,0 +1,253 @@
+<!DOCTYPE html>
+<html>
+<head>
+<script src=""
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
+<script>
+
+description("Test the unprefixed animation properties.");
+
+// These have to be global for the test helpers to see them.
+var stylesheet, cssRule, declaration, animationRule, subRule, animationStyle;
+var styleElement = document.createElement("style");
+document.head.appendChild(styleElement);
+stylesheet = styleElement.sheet;
+
+function testAnimationRule(description, property, value, expectedTexts)
+{
+    debug("");
+    debug("Parsing - " + description + " : " + value);
+
+    stylesheet.insertRule("section { " + property + ": " + value + "; }", 0);
+    cssRule = stylesheet.cssRules.item(0);
+
+    shouldBe("cssRule.type", "1");
+
+    declaration = cssRule.style;
+    shouldBe("declaration.length", "2"); // We set both the prefixed and unprefixed version.
+    shouldBe("declaration.getPropertyValue('" + property + "')", "'" + value + "'");
+    shouldBe("declaration.getPropertyValue('-webkit-" + property + "')", "'" + value + "'");
+
+    animationRule = declaration.getPropertyCSSValue(property);
+
+    if (animationRule && animationRule.length > 1 && expectedTexts && expectedTexts.length > 1) {
+        for (var i = 0; i < expectedTexts.length; i++) {
+            subRule = animationRule[i];
+            shouldBe("subRule.cssText", "'" + expectedTexts[i] + "'");
+        }
+    }
+
+    stylesheet.deleteRule(0);
+}
+
+function testInvalidAnimationRule(description, property, value)
+{
+    debug("");
+    debug("Invalid - " + description + " : " + value);
+
+    stylesheet.insertRule("section { " + property + ": " + value + "; }", 0);
+    cssRule = stylesheet.cssRules.item(0);
+
+    shouldBe("cssRule.type", "1");
+
+    declaration = cssRule.style;
+    shouldBe("declaration.length", "0");
+    shouldBe("declaration.getPropertyValue('" + property + "')", "null");
+
+    stylesheet.deleteRule(0);
+}
+
+function testComputedAnimationRule(description, property, value, expectedTexts)
+{
+    debug("");
+    debug("Computed Style - " + description + " : " + value);
+
+    stylesheet.insertRule("body { " + property + ": " + value + "; }", 0);
+
+    animationStyle = window.getComputedStyle(document.body).getPropertyCSSValue(property);
+
+    if (animationStyle && animationStyle.length > 1 && expectedTexts && expectedTexts.length > 1) {
+        for (var i = 0; i < expectedTexts.length; i++) {
+            subRule = animationStyle[i];
+            shouldBe("subRule.cssText", "'" + expectedTexts[i] + "'");
+        }
+    } else
+        shouldBe("animationStyle.cssText", "'" + value + "'");
+
+    stylesheet.deleteRule(0);
+}
+
+
+testAnimationRule("Basic animation-name",
+                  "animation-name", "waldo");
+
+testAnimationRule("Multiple animation-names",
+                  "animation-name", "waldo, wally",
+                  ["waldo", "wally"]);
+
+testAnimationRule("Basic animation-duration",
+                  "animation-duration", "5s");
+
+testAnimationRule("Multiple animation-durations",
+                  "animation-duration", "10s, 20ms",
+                  ["10s", "20ms"]);
+
+testAnimationRule("Basic animation-delay",
+                  "animation-delay", "5s");
+
+testAnimationRule("Multiple animation-delays",
+                  "animation-delay", "10s, 20ms",
+                  ["10s", "20ms"]);
+
+testAnimationRule("Basic animation-timing-function",
+                  "animation-timing-function", "ease-in-out");
+
+testAnimationRule("animation-timing-function with bezier",
+                  "animation-timing-function", "cubic-bezier(0.2, 0.3, 0.4, 0.5)");
+
+testAnimationRule("Multiple animation-timing-functions",
+                  "animation-timing-function", "ease-in, ease-out",
+                  ["ease-in", "ease-out"]);
+
+testAnimationRule("Basic animation-iteration-count",
+                  "animation-iteration-count", "4");
+
+testAnimationRule("animation-iteration-count with keyword",
+                  "animation-iteration-count", "infinite");
+
+testAnimationRule("Multiple animation-iteration-counts",
+                  "animation-iteration-count", "2, infinite, 4",
+                  ["2", "infinite", "4"]);
+
+testAnimationRule("Normal animation-direction",
+                  "animation-direction", "normal");
+
+testAnimationRule("Alternate animation-direction",
+                  "animation-direction", "alternate");
+
+testAnimationRule("Reverse animation-direction",
+                  "animation-direction", "reverse");
+
+testAnimationRule("Alternate Reverse animation-direction",
+                  "animation-direction", "alternate-reverse");
+
+testAnimationRule("Multiple animation-directions",
+                  "animation-direction", "alternate, alternate, normal",
+                  ["alternate", "alternate", "normal"]);
+
+testAnimationRule("None animation-fill-mode",
+                  "animation-fill-mode", "none");
+
+testAnimationRule("Forwards animation-fill-mode",
+                  "animation-fill-mode", "forwards");
+
+testAnimationRule("Backwards animation-fill-mode",
+                  "animation-fill-mode", "backwards");
+
+testAnimationRule("Both animation-fill-mode",
+                  "animation-fill-mode", "both");
+
+testAnimationRule("Multiple animation-fill-modes",
+                  "animation-fill-mode", "none, forwards, backwards, both",
+                  ["none", "forwards", "backwards", "both"]);
+
+testInvalidAnimationRule("duration - Bad value", "animation-duration", "10cm");
+testInvalidAnimationRule("duration - List with bad value", "animation-duration", "10ms, 10cm, 10s");
+
+testInvalidAnimationRule("delay - Bad value", "animation-delay", "10cm");
+testInvalidAnimationRule("delay - List with bad value", "animation-delay", "10ms, 10cm, 10s");
+
+testInvalidAnimationRule("timing-function - Wrong keyword parameter", "animation-timing-function", "egg");
+testInvalidAnimationRule("timing-function - List with wrong keyword parameter", "animation-timing-function", "ease-in, egg, ease-out");
+
+testInvalidAnimationRule("iteration-count - Wrong keyword parameter", "animation-iteration-count", "banana");
+testInvalidAnimationRule("iteration-count - List with wrong keyword parameter", "animation-iteration-count", "infinite, 10, banana");
+
+testInvalidAnimationRule("direction - Wrong keyword parameter", "animation-direction", "all");
+testInvalidAnimationRule("direction - List with wrong keyword parameter", "animation-direction", "normal, alternate, none");
+
+testInvalidAnimationRule("fill-mode - Wrong keyword parameter", "animation-fill-mode", "all");
+testInvalidAnimationRule("fill-mode - List with wrong keyword parameter", "animation-fill-mode", "none, backwards, left, alternate, forwards");
+
+testComputedAnimationRule("Basic animation-name",
+                          "animation-name", "waldo");
+
+testComputedAnimationRule("Multiple animation-names",
+                          "animation-name", "waldo, wally",
+                          ["waldo", "wally"]);
+
+testComputedAnimationRule("Basic animation-duration",
+                          "animation-duration", "5s");
+
+testComputedAnimationRule("Multiple animation-durations",
+                          "animation-duration", "10s, 20ms",
+                          ["10s", "0.02s"]);
+
+testComputedAnimationRule("Basic animation-delay",
+                          "animation-delay", "5s");
+
+testComputedAnimationRule("Multiple animation-delays",
+                          "animation-delay", "10s, 20ms",
+                          ["10s", "0.02s"]);
+
+testComputedAnimationRule("Basic animation-timing-function",
+                          "animation-timing-function", "ease-in-out");
+
+testComputedAnimationRule("animation-timing-function with bezier",
+                          "animation-timing-function", "cubic-bezier(0.2, 0.3, 0.4, 0.5)");
+
+testComputedAnimationRule("Multiple animation-timing-functions",
+                          "animation-timing-function", "ease-in, ease-out",
+                          ["ease-in", "ease-out"]);
+
+testComputedAnimationRule("Basic animation-iteration-count",
+                          "animation-iteration-count", "4");
+
+testComputedAnimationRule("animation-iteration-count with keyword",
+                          "animation-iteration-count", "infinite");
+
+testComputedAnimationRule("Multiple animation-iteration-counts",
+                          "animation-iteration-count", "2, infinite, 4",
+                          ["2", "infinite", "4"]);
+
+testComputedAnimationRule("Normal animation-direction",
+                          "animation-direction", "normal");
+
+testComputedAnimationRule("Alternate animation-direction",
+                          "animation-direction", "alternate");
+
+testComputedAnimationRule("Reverse animation-direction",
+                          "animation-direction", "reverse");
+
+testComputedAnimationRule("Alternate Reverse animation-direction",
+                          "animation-direction", "alternate-reverse");
+
+testComputedAnimationRule("Multiple animation-directions",
+                          "animation-direction", "alternate, alternate, normal",
+                          ["alternate", "alternate", "normal"]);
+
+testComputedAnimationRule("None animation-fill-mode",
+                          "animation-fill-mode", "none");
+
+testComputedAnimationRule("Forwards animation-fill-mode",
+                          "animation-fill-mode", "forwards");
+
+testComputedAnimationRule("Backwards animation-fill-mode",
+                          "animation-fill-mode", "backwards");
+
+testComputedAnimationRule("Both animation-fill-mode",
+                          "animation-fill-mode", "both");
+
+testComputedAnimationRule("Multiple animation-fill-modes",
+                          "animation-fill-mode", "none, forwards, backwards, both",
+                          ["none", "forwards", "backwards", "both"]);
+
+successfullyParsed = true;
+
+</script>
+<script src=""
+</body>
+</html>
Property changes on: trunk/LayoutTests/animations/unprefixed-properties.html
___________________________________________________________________

Added: svn:mime-type

Added: svn:keywords

Added: svn:eol-style

Added: trunk/LayoutTests/animations/unprefixed-shorthand-expected.txt (0 => 176050)


--- trunk/LayoutTests/animations/unprefixed-shorthand-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/animations/unprefixed-shorthand-expected.txt	2014-11-13 01:23:15 UTC (rev 176050)
@@ -0,0 +1,137 @@
+Test the unprefixed animation shorthand.
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+
+Setting animation: waldo
+Check animation-name
+PASS animationStyle.cssText is 'waldo'
+Check animation-duration
+PASS animationStyle.cssText is '0s'
+Check animation-delay
+PASS animationStyle.cssText is '0s'
+Check animation-timing-function
+PASS animationStyle.cssText is 'ease'
+Check animation-iteration-count
+PASS animationStyle.cssText is '1'
+Check animation-direction
+PASS animationStyle.cssText is 'normal'
+Check animation-fill-mode
+PASS animationStyle.cssText is 'none'
+
+Setting animation: waldo 2s
+Check animation-name
+PASS animationStyle.cssText is 'waldo'
+Check animation-duration
+PASS animationStyle.cssText is '2s'
+Check animation-delay
+PASS animationStyle.cssText is '0s'
+Check animation-timing-function
+PASS animationStyle.cssText is 'ease'
+Check animation-iteration-count
+PASS animationStyle.cssText is '1'
+Check animation-direction
+PASS animationStyle.cssText is 'normal'
+Check animation-fill-mode
+PASS animationStyle.cssText is 'none'
+
+Setting animation: 3s banana 500ms
+Check animation-name
+PASS animationStyle.cssText is 'banana'
+Check animation-duration
+PASS animationStyle.cssText is '3s'
+Check animation-delay
+PASS animationStyle.cssText is '0.5s'
+Check animation-timing-function
+PASS animationStyle.cssText is 'ease'
+Check animation-iteration-count
+PASS animationStyle.cssText is '1'
+Check animation-direction
+PASS animationStyle.cssText is 'normal'
+Check animation-fill-mode
+PASS animationStyle.cssText is 'none'
+
+Setting animation: infinite alternate eggs 5s
+Check animation-name
+PASS animationStyle.cssText is 'eggs'
+Check animation-duration
+PASS animationStyle.cssText is '5s'
+Check animation-delay
+PASS animationStyle.cssText is '0s'
+Check animation-timing-function
+PASS animationStyle.cssText is 'ease'
+Check animation-iteration-count
+PASS animationStyle.cssText is 'infinite'
+Check animation-direction
+PASS animationStyle.cssText is 'alternate'
+Check animation-fill-mode
+PASS animationStyle.cssText is 'none'
+
+Setting animation: forwards normal ease-in-out bacon 1s 2s
+Check animation-name
+PASS animationStyle.cssText is 'bacon'
+Check animation-duration
+PASS animationStyle.cssText is '1s'
+Check animation-delay
+PASS animationStyle.cssText is '2s'
+Check animation-timing-function
+PASS animationStyle.cssText is 'ease-in-out'
+Check animation-iteration-count
+PASS animationStyle.cssText is '1'
+Check animation-direction
+PASS animationStyle.cssText is 'normal'
+Check animation-fill-mode
+PASS animationStyle.cssText is 'forwards'
+
+Setting animation: pastrami 100ms cubic-bezier(0, 0, 1, 1) alternate-reverse
+Check animation-name
+PASS animationStyle.cssText is 'pastrami'
+Check animation-duration
+PASS animationStyle.cssText is '0.1s'
+Check animation-delay
+PASS animationStyle.cssText is '0s'
+Check animation-timing-function
+PASS animationStyle.cssText is 'cubic-bezier(0, 0, 1, 1)'
+Check animation-iteration-count
+PASS animationStyle.cssText is '1'
+Check animation-direction
+PASS animationStyle.cssText is 'alternate-reverse'
+Check animation-fill-mode
+PASS animationStyle.cssText is 'none'
+
+Setting animation: slightly-invalid 2s a
+Check animation-name
+PASS animationStyle.cssText is 'none'
+Check animation-duration
+PASS animationStyle.cssText is '0s'
+Check animation-delay
+PASS animationStyle.cssText is '0s'
+Check animation-timing-function
+PASS animationStyle.cssText is 'ease'
+Check animation-iteration-count
+PASS animationStyle.cssText is '1'
+Check animation-direction
+PASS animationStyle.cssText is 'normal'
+Check animation-fill-mode
+PASS animationStyle.cssText is 'none'
+
+Setting animation: completely invalid
+Check animation-name
+PASS animationStyle.cssText is 'none'
+Check animation-duration
+PASS animationStyle.cssText is '0s'
+Check animation-delay
+PASS animationStyle.cssText is '0s'
+Check animation-timing-function
+PASS animationStyle.cssText is 'ease'
+Check animation-iteration-count
+PASS animationStyle.cssText is '1'
+Check animation-direction
+PASS animationStyle.cssText is 'normal'
+Check animation-fill-mode
+PASS animationStyle.cssText is 'none'
+PASS successfullyParsed is true
+
+TEST COMPLETE
+
Property changes on: trunk/LayoutTests/animations/unprefixed-shorthand-expected.txt
___________________________________________________________________

Added: svn:mime-type

Added: svn:keywords

Added: svn:eol-style

Added: trunk/LayoutTests/animations/unprefixed-shorthand.html (0 => 176050)


--- trunk/LayoutTests/animations/unprefixed-shorthand.html	                        (rev 0)
+++ trunk/LayoutTests/animations/unprefixed-shorthand.html	2014-11-13 01:23:15 UTC (rev 176050)
@@ -0,0 +1,133 @@
+<!DOCTYPE html>
+<html>
+<head>
+<script src=""
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
+<script>
+
+description("Test the unprefixed animation shorthand.");
+
+// These have to be global for the test helpers to see them.
+var stylesheet, animationStyle;
+var styleElement = document.createElement("style");
+document.head.appendChild(styleElement);
+stylesheet = styleElement.sheet;
+
+function testAnimationShorthand(value, expectedName, expectedDuration, expectedDelay, expectedTimingFunction, expectedIterationCount, expectedDirection, expectedFillMode)
+{
+    debug("");
+    debug("Setting animation: " + value);
+    stylesheet.insertRule("body { animation: " + value + "; }", 0);
+
+    debug("Check animation-name");
+    animationStyle = window.getComputedStyle(document.body).getPropertyCSSValue("animation-name");
+    shouldBe("animationStyle.cssText", "'" + expectedName + "'");
+
+    debug("Check animation-duration");
+    animationStyle = window.getComputedStyle(document.body).getPropertyCSSValue("animation-duration");
+    shouldBe("animationStyle.cssText", "'" + expectedDuration + "'");
+
+    debug("Check animation-delay");
+    animationStyle = window.getComputedStyle(document.body).getPropertyCSSValue("animation-delay");
+    shouldBe("animationStyle.cssText", "'" + expectedDelay + "'");
+
+    debug("Check animation-timing-function");
+    animationStyle = window.getComputedStyle(document.body).getPropertyCSSValue("animation-timing-function");
+    shouldBe("animationStyle.cssText", "'" + expectedTimingFunction + "'");
+
+    debug("Check animation-iteration-count");
+    animationStyle = window.getComputedStyle(document.body).getPropertyCSSValue("animation-iteration-count");
+    shouldBe("animationStyle.cssText", "'" + expectedIterationCount + "'");
+
+    debug("Check animation-direction");
+    animationStyle = window.getComputedStyle(document.body).getPropertyCSSValue("animation-direction");
+    shouldBe("animationStyle.cssText", "'" + expectedDirection + "'");
+
+    debug("Check animation-fill-mode");
+    animationStyle = window.getComputedStyle(document.body).getPropertyCSSValue("animation-fill-mode");
+    shouldBe("animationStyle.cssText", "'" + expectedFillMode + "'");
+
+    stylesheet.deleteRule(0);
+}
+
+testAnimationShorthand("waldo",
+                       "waldo",
+                       "0s",
+                       "0s",
+                       "ease",
+                       "1",
+                       "normal",
+                       "none");
+
+testAnimationShorthand("waldo 2s",
+                       "waldo",
+                       "2s",
+                       "0s",
+                       "ease",
+                       "1",
+                       "normal",
+                       "none");
+
+testAnimationShorthand("3s banana 500ms",
+                       "banana",
+                       "3s",
+                       "0.5s",
+                       "ease",
+                       "1",
+                       "normal",
+                       "none");
+
+testAnimationShorthand("infinite alternate eggs 5s",
+                       "eggs",
+                       "5s",
+                       "0s",
+                       "ease",
+                       "infinite",
+                       "alternate",
+                       "none");
+
+testAnimationShorthand("forwards normal ease-in-out bacon 1s 2s",
+                       "bacon",
+                       "1s",
+                       "2s",
+                       "ease-in-out",
+                       "1",
+                       "normal",
+                       "forwards");
+
+testAnimationShorthand("pastrami 100ms cubic-bezier(0, 0, 1, 1) alternate-reverse",
+                       "pastrami",
+                       "0.1s",
+                       "0s",
+                       "cubic-bezier(0, 0, 1, 1)",
+                       "1",
+                       "alternate-reverse",
+                       "none");
+
+testAnimationShorthand("slightly-invalid 2s a",
+                       "none",
+                       "0s",
+                       "0s",
+                       "ease",
+                       "1",
+                       "normal",
+                       "none");
+
+testAnimationShorthand("completely invalid",
+                       "none",
+                       "0s",
+                       "0s",
+                       "ease",
+                       "1",
+                       "normal",
+                       "none");
+
+successfullyParsed = true;
+
+</script>
+<script src=""
+</body>
+</html>
Property changes on: trunk/LayoutTests/animations/unprefixed-shorthand.html
___________________________________________________________________

Added: svn:mime-type

Added: svn:keywords

Added: svn:eol-style

Modified: trunk/Source/WebCore/ChangeLog (176049 => 176050)


--- trunk/Source/WebCore/ChangeLog	2014-11-13 00:27:17 UTC (rev 176049)
+++ trunk/Source/WebCore/ChangeLog	2014-11-13 01:23:15 UTC (rev 176050)
@@ -1,3 +1,71 @@
+2014-11-12  Dean Jackson  <[email protected]>
+
+        Support unprefixed animation property names
+        https://bugs.webkit.org/show_bug.cgi?id=138678
+        <rdar://problem/18943059>
+
+        Reviewed by Simon Fraser.
+
+        Step 1 of 3 in unprefixing CSS animations: handling the
+        property names and values.
+
+        Unlike other unprefixing, where we use an alias that
+        effectively removes the prefixed values from the code,
+        for animations we need to keep the old values around so that
+        existing content will not break (e.g. computed style).
+
+        During testing I noticed that we didn't handle the
+        (relatively) new animation-direction values of
+        "reverse" and "alternate-reverse" when querying
+        computed style.
+
+        Tests: animations/unprefixed-properties.html
+               animations/unprefixed-shorthand.html
+
+        * css/CSSComputedStyleDeclaration.cpp:
+        (WebCore::ComputedStyleExtractor::propertyValue): Handle the unprefixed
+        values, but also get animation direction to produce the correct
+        results when "reverse" and "alternate-reverse" is specified.
+
+        * css/CSSParser.cpp: Handle the new values. If necessary, pass a flag
+        around indicating whether it is prefixed or unprefixed.
+        (WebCore::CSSParser::parseValue):
+        (WebCore::CSSParser::parseAnimationShorthand): Use the flag to decide
+        which of the forms we're going to check.
+        (WebCore::CSSParser::parseAnimationProperty):
+        * css/CSSParser.h:
+
+        * css/CSSProperty.h:
+        (WebCore::prefixingVariantForPropertyId): Add prefixing/unprefixing variants for
+        all the animation values, and clean up the code a bit.
+
+        * css/CSSPropertyNames.in: Add new properties.
+
+        * css/DeprecatedStyleBuilder.cpp:
+        (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder): We need handlers for the
+        unprefixed forms. This should move to the new StyleBuilder soon.
+
+        * css/StyleProperties.cpp: Handle new values.
+        (WebCore::StyleProperties::getPropertyValue):
+        (WebCore::StyleProperties::asText):
+
+        * css/StylePropertyShorthand.cpp:
+        (WebCore::animationShorthand):
+        (WebCore::animationShorthandForParsing): Decide which list of properties to use.
+        (WebCore::shorthandForProperty):
+        (WebCore::matchingShorthandsForLonghand):
+        (WebCore::webkitAnimationShorthandForParsing): Deleted.
+        * css/StylePropertyShorthand.h:
+
+        * css/StyleResolver.cpp: Since the new properties come before "background" in
+        alphabetical order, they are earlier in the CSSPropertyNames.in file, and thus
+        we need to update the call sites that think CSSPropertyBackground is the first
+        property.
+        (WebCore::StyleResolver::styleForKeyframe): Replace CSSPropertyBackground with CSSPropertyAnimation.
+        (WebCore::StyleResolver::styleForPage):
+        (WebCore::StyleResolver::applyMatchedProperties):
+        (WebCore::StyleResolver::applyProperty):
+
 2014-11-12  Beth Dakin  <[email protected]>
 
         Speculative build fix.

Modified: trunk/Source/WebCore/css/CSSComputedStyleDeclaration.cpp (176049 => 176050)


--- trunk/Source/WebCore/css/CSSComputedStyleDeclaration.cpp	2014-11-13 00:27:17 UTC (rev 176049)
+++ trunk/Source/WebCore/css/CSSComputedStyleDeclaration.cpp	2014-11-13 01:23:15 UTC (rev 176050)
@@ -92,6 +92,14 @@
 // List of all properties we know how to compute, omitting shorthands.
 static const CSSPropertyID computedProperties[] = {
     CSSPropertyAlt,
+    CSSPropertyAnimationDelay,
+    CSSPropertyAnimationDirection,
+    CSSPropertyAnimationDuration,
+    CSSPropertyAnimationFillMode,
+    CSSPropertyAnimationIterationCount,
+    CSSPropertyAnimationName,
+    CSSPropertyAnimationPlayState,
+    CSSPropertyAnimationTimingFunction,
     CSSPropertyBackgroundAttachment,
     CSSPropertyBackgroundBlendMode,
     CSSPropertyBackgroundClip,
@@ -224,7 +232,6 @@
 #endif
     CSSPropertyZIndex,
     CSSPropertyZoom,
-
     CSSPropertyWebkitAnimationDelay,
     CSSPropertyWebkitAnimationDirection,
     CSSPropertyWebkitAnimationDuration,
@@ -2571,24 +2578,38 @@
             return cssValuePool().createValue(firstRegion.release());
         }
 #endif
+        case CSSPropertyAnimationDelay:
         case CSSPropertyWebkitAnimationDelay:
             return getDelayValue(style->animations());
+        case CSSPropertyAnimationDirection:
         case CSSPropertyWebkitAnimationDirection: {
             RefPtr<CSSValueList> list = CSSValueList::createCommaSeparated();
             const AnimationList* t = style->animations();
             if (t) {
                 for (size_t i = 0; i < t->size(); ++i) {
-                    if (t->animation(i).direction())
+                    switch (t->animation(i).direction()) {
+                    case Animation::AnimationDirectionNormal:
+                        list->append(cssValuePool().createIdentifierValue(CSSValueNormal));
+                        break;
+                    case Animation::AnimationDirectionAlternate:
                         list->append(cssValuePool().createIdentifierValue(CSSValueAlternate));
-                    else
-                        list->append(cssValuePool().createIdentifierValue(CSSValueNormal));
+                        break;
+                    case Animation::AnimationDirectionReverse:
+                        list->append(cssValuePool().createIdentifierValue(CSSValueReverse));
+                        break;
+                    case Animation::AnimationDirectionAlternateReverse:
+                        list->append(cssValuePool().createIdentifierValue(CSSValueAlternateReverse));
+                        break;
+                    }
                 }
             } else
                 list->append(cssValuePool().createIdentifierValue(CSSValueNormal));
             return list.release();
         }
+        case CSSPropertyAnimationDuration:
         case CSSPropertyWebkitAnimationDuration:
             return getDurationValue(style->animations());
+        case CSSPropertyAnimationFillMode:
         case CSSPropertyWebkitAnimationFillMode: {
             RefPtr<CSSValueList> list = CSSValueList::createCommaSeparated();
             const AnimationList* t = style->animations();
@@ -2613,6 +2634,7 @@
                 list->append(cssValuePool().createIdentifierValue(CSSValueNone));
             return list.release();
         }
+        case CSSPropertyAnimationIterationCount:
         case CSSPropertyWebkitAnimationIterationCount: {
             RefPtr<CSSValueList> list = CSSValueList::createCommaSeparated();
             const AnimationList* t = style->animations();
@@ -2628,6 +2650,7 @@
                 list->append(cssValuePool().createValue(Animation::initialAnimationIterationCount(), CSSPrimitiveValue::CSS_NUMBER));
             return list.release();
         }
+        case CSSPropertyAnimationName:
         case CSSPropertyWebkitAnimationName: {
             RefPtr<CSSValueList> list = CSSValueList::createCommaSeparated();
             const AnimationList* t = style->animations();
@@ -2638,6 +2661,7 @@
                 list->append(cssValuePool().createIdentifierValue(CSSValueNone));
             return list.release();
         }
+        case CSSPropertyAnimationPlayState:
         case CSSPropertyWebkitAnimationPlayState: {
             RefPtr<CSSValueList> list = CSSValueList::createCommaSeparated();
             const AnimationList* t = style->animations();
@@ -2653,6 +2677,7 @@
                 list->append(cssValuePool().createIdentifierValue(CSSValueRunning));
             return list.release();
         }
+        case CSSPropertyAnimationTimingFunction:
         case CSSPropertyWebkitAnimationTimingFunction:
             return getTimingFunctionValue(style->animations());
         case CSSPropertyWebkitAppearance:
@@ -2999,6 +3024,7 @@
             return zoomAdjustedPixelValueForLength(style->svgStyle().y(), style.get());
 
         /* Unimplemented CSS 3 properties (including CSS3 shorthand properties) */
+        case CSSPropertyAnimation:
         case CSSPropertyWebkitTextEmphasis:
         case CSSPropertyTextLineThrough:
         case CSSPropertyTextLineThroughColor:

Modified: trunk/Source/WebCore/css/CSSParser.cpp (176049 => 176050)


--- trunk/Source/WebCore/css/CSSParser.cpp	2014-11-13 00:27:17 UTC (rev 176049)
+++ trunk/Source/WebCore/css/CSSParser.cpp	2014-11-13 01:23:15 UTC (rev 176050)
@@ -2593,6 +2593,14 @@
         }
         return false;
     }
+    case CSSPropertyAnimationDelay:
+    case CSSPropertyAnimationDirection:
+    case CSSPropertyAnimationDuration:
+    case CSSPropertyAnimationFillMode:
+    case CSSPropertyAnimationName:
+    case CSSPropertyAnimationPlayState:
+    case CSSPropertyAnimationIterationCount:
+    case CSSPropertyAnimationTimingFunction:
     case CSSPropertyWebkitAnimationDelay:
     case CSSPropertyWebkitAnimationDirection:
     case CSSPropertyWebkitAnimationDuration:
@@ -2880,8 +2888,9 @@
         return parseShorthand(propId, webkitColumnRuleShorthand(), important);
     case CSSPropertyWebkitTextStroke:
         return parseShorthand(propId, webkitTextStrokeShorthand(), important);
+    case CSSPropertyAnimation:
     case CSSPropertyWebkitAnimation:
-        return parseAnimationShorthand(important);
+        return parseAnimationShorthand(propId, important);
     case CSSPropertyTransition:
     case CSSPropertyWebkitTransition:
         return parseTransitionShorthand(propId, important);
@@ -3433,18 +3442,21 @@
     lval = WTF::move(list);
 }
 
-bool CSSParser::parseAnimationShorthand(bool important)
+bool CSSParser::parseAnimationShorthand(CSSPropertyID propId, bool important)
 {
-    const StylePropertyShorthand& animationProperties = webkitAnimationShorthandForParsing();
+    ASSERT(propId == CSSPropertyAnimation || propId == CSSPropertyWebkitAnimation);
+
     const unsigned numProperties = 7;
+    const StylePropertyShorthand& shorthand = animationShorthandForParsing(propId);
 
     // The list of properties in the shorthand should be the same
     // length as the list with animation name in last position, even though they are
     // in a different order.
-    ASSERT(numProperties == webkitAnimationShorthandForParsing().length());
+    ASSERT(numProperties == shorthand.length());
+    ASSERT(numProperties == animationShorthand().length());
     ASSERT(numProperties == webkitAnimationShorthand().length());
 
-    ShorthandScope scope(this, CSSPropertyWebkitAnimation);
+    ShorthandScope scope(this, propId);
 
     bool parsedProperty[numProperties] = { false };
     AnimationParseContext context;
@@ -3470,7 +3482,7 @@
         for (i = 0; i < numProperties; ++i) {
             if (!parsedProperty[i]) {
                 RefPtr<CSSValue> val;
-                if (parseAnimationProperty(animationProperties.properties()[i], val, context)) {
+                if (parseAnimationProperty(shorthand.properties()[i], val, context)) {
                     parsedProperty[i] = found = true;
                     addAnimationValue(values[i], val.releaseNonNull());
                     break;
@@ -3493,7 +3505,7 @@
         if (!parsedProperty[i])
             addAnimationValue(values[i], cssValuePool().createImplicitInitialValue());
 
-        addProperty(animationProperties.properties()[i], values[i].release(), important);
+        addProperty(shorthand.properties()[i], values[i].release(), important);
     }
 
     return true;
@@ -4762,63 +4774,71 @@
         }
         else {
             switch (propId) {
-                case CSSPropertyWebkitAnimationDelay:
-                case CSSPropertyTransitionDelay:
-                case CSSPropertyWebkitTransitionDelay:
-                    currValue = parseAnimationDelay();
-                    if (currValue)
-                        m_valueList->next();
-                    break;
-                case CSSPropertyWebkitAnimationDirection:
-                    currValue = parseAnimationDirection();
-                    if (currValue)
-                        m_valueList->next();
-                    break;
-                case CSSPropertyWebkitAnimationDuration:
-                case CSSPropertyTransitionDuration:
-                case CSSPropertyWebkitTransitionDuration:
-                    currValue = parseAnimationDuration();
-                    if (currValue)
-                        m_valueList->next();
-                    break;
-                case CSSPropertyWebkitAnimationFillMode:
-                    currValue = parseAnimationFillMode();
-                    if (currValue)
-                        m_valueList->next();
-                    break;
-                case CSSPropertyWebkitAnimationIterationCount:
-                    currValue = parseAnimationIterationCount();
-                    if (currValue)
-                        m_valueList->next();
-                    break;
-                case CSSPropertyWebkitAnimationName:
-                    currValue = parseAnimationName();
-                    if (currValue)
-                        m_valueList->next();
-                    break;
-                case CSSPropertyWebkitAnimationPlayState:
-                    currValue = parseAnimationPlayState();
-                    if (currValue)
-                        m_valueList->next();
-                    break;
-                case CSSPropertyTransitionProperty:
-                case CSSPropertyWebkitTransitionProperty:
-                    currValue = parseAnimationProperty(context);
-                    if (value && !context.animationPropertyKeywordAllowed())
-                        return false;
-                    if (currValue)
-                        m_valueList->next();
-                    break;
-                case CSSPropertyWebkitAnimationTimingFunction:
-                case CSSPropertyTransitionTimingFunction:
-                case CSSPropertyWebkitTransitionTimingFunction:
-                    currValue = parseAnimationTimingFunction();
-                    if (currValue)
-                        m_valueList->next();
-                    break;
-                default:
-                    ASSERT_NOT_REACHED();
+            case CSSPropertyAnimationDelay:
+            case CSSPropertyWebkitAnimationDelay:
+            case CSSPropertyTransitionDelay:
+            case CSSPropertyWebkitTransitionDelay:
+                currValue = parseAnimationDelay();
+                if (currValue)
+                    m_valueList->next();
+                break;
+            case CSSPropertyAnimationDirection:
+            case CSSPropertyWebkitAnimationDirection:
+                currValue = parseAnimationDirection();
+                if (currValue)
+                    m_valueList->next();
+                break;
+            case CSSPropertyAnimationDuration:
+            case CSSPropertyWebkitAnimationDuration:
+            case CSSPropertyTransitionDuration:
+            case CSSPropertyWebkitTransitionDuration:
+                currValue = parseAnimationDuration();
+                if (currValue)
+                    m_valueList->next();
+                break;
+            case CSSPropertyAnimationFillMode:
+            case CSSPropertyWebkitAnimationFillMode:
+                currValue = parseAnimationFillMode();
+                if (currValue)
+                    m_valueList->next();
+                break;
+            case CSSPropertyAnimationIterationCount:
+            case CSSPropertyWebkitAnimationIterationCount:
+                currValue = parseAnimationIterationCount();
+                if (currValue)
+                    m_valueList->next();
+                break;
+            case CSSPropertyAnimationName:
+            case CSSPropertyWebkitAnimationName:
+                currValue = parseAnimationName();
+                if (currValue)
+                    m_valueList->next();
+                break;
+            case CSSPropertyAnimationPlayState:
+            case CSSPropertyWebkitAnimationPlayState:
+                currValue = parseAnimationPlayState();
+                if (currValue)
+                    m_valueList->next();
+                break;
+            case CSSPropertyTransitionProperty:
+            case CSSPropertyWebkitTransitionProperty:
+                currValue = parseAnimationProperty(context);
+                if (value && !context.animationPropertyKeywordAllowed())
                     return false;
+                if (currValue)
+                    m_valueList->next();
+                break;
+            case CSSPropertyAnimationTimingFunction:
+            case CSSPropertyWebkitAnimationTimingFunction:
+            case CSSPropertyTransitionTimingFunction:
+            case CSSPropertyWebkitTransitionTimingFunction:
+                currValue = parseAnimationTimingFunction();
+                if (currValue)
+                    m_valueList->next();
+                break;
+            default:
+                ASSERT_NOT_REACHED();
+                return false;
             }
 
             if (!currValue)

Modified: trunk/Source/WebCore/css/CSSParser.h (176049 => 176050)


--- trunk/Source/WebCore/css/CSSParser.h	2014-11-13 00:27:17 UTC (rev 176049)
+++ trunk/Source/WebCore/css/CSSParser.h	2014-11-13 01:23:15 UTC (rev 176050)
@@ -153,7 +153,7 @@
     bool parseCubicBezierTimingFunctionValue(CSSParserValueList*& args, double& result);
     bool parseAnimationProperty(CSSPropertyID, RefPtr<CSSValue>&, AnimationParseContext&);
     bool parseTransitionShorthand(CSSPropertyID, bool important);
-    bool parseAnimationShorthand(bool important);
+    bool parseAnimationShorthand(CSSPropertyID, bool important);
 
 #if ENABLE(CSS_GRID_LAYOUT)
     PassRefPtr<CSSValue> parseGridPosition();

Modified: trunk/Source/WebCore/css/CSSProperty.h (176049 => 176050)


--- trunk/Source/WebCore/css/CSSProperty.h	2014-11-13 00:27:17 UTC (rev 176049)
+++ trunk/Source/WebCore/css/CSSProperty.h	2014-11-13 01:23:15 UTC (rev 176050)
@@ -81,46 +81,70 @@
     RefPtr<CSSValue> m_value;
 };
 
-inline CSSPropertyID prefixingVariantForPropertyId(CSSPropertyID propId)
+inline CSSPropertyID prefixingVariantForPropertyId(CSSPropertyID propertyID)
 {
-    CSSPropertyID propertyId = CSSPropertyInvalid;
-    switch (propId) {
+    ASSERT(propertyID != CSSPropertyInvalid);
+
+    switch (propertyID) {
+    case CSSPropertyAnimation:
+        return CSSPropertyWebkitAnimation;
+    case CSSPropertyAnimationDelay:
+        return CSSPropertyWebkitAnimationDelay;
+    case CSSPropertyAnimationDirection:
+        return CSSPropertyWebkitAnimationDirection;
+    case CSSPropertyAnimationDuration:
+        return CSSPropertyWebkitAnimationDuration;
+    case CSSPropertyAnimationFillMode:
+        return CSSPropertyWebkitAnimationFillMode;
+    case CSSPropertyAnimationName:
+        return CSSPropertyWebkitAnimationName;
+    case CSSPropertyAnimationPlayState:
+        return CSSPropertyWebkitAnimationPlayState;
+    case CSSPropertyAnimationIterationCount:
+        return CSSPropertyWebkitAnimationIterationCount;
+    case CSSPropertyAnimationTimingFunction:
+        return CSSPropertyWebkitAnimationTimingFunction;
+    case CSSPropertyWebkitAnimation:
+        return CSSPropertyAnimation;
+    case CSSPropertyWebkitAnimationDelay:
+        return CSSPropertyAnimationDelay;
+    case CSSPropertyWebkitAnimationDirection:
+        return CSSPropertyAnimationDirection;
+    case CSSPropertyWebkitAnimationDuration:
+        return CSSPropertyAnimationDuration;
+    case CSSPropertyWebkitAnimationFillMode:
+        return CSSPropertyAnimationFillMode;
+    case CSSPropertyWebkitAnimationName:
+        return CSSPropertyAnimationName;
+    case CSSPropertyWebkitAnimationPlayState:
+        return CSSPropertyAnimationPlayState;
+    case CSSPropertyWebkitAnimationIterationCount:
+        return CSSPropertyAnimationIterationCount;
+    case CSSPropertyWebkitAnimationTimingFunction:
+        return CSSPropertyAnimationTimingFunction;
     case CSSPropertyTransitionDelay:
-        propertyId = CSSPropertyWebkitTransitionDelay;
-        break;
+        return CSSPropertyWebkitTransitionDelay;
     case CSSPropertyTransitionDuration:
-        propertyId = CSSPropertyWebkitTransitionDuration;
-        break;
+        return CSSPropertyWebkitTransitionDuration;
     case CSSPropertyTransitionProperty:
-        propertyId = CSSPropertyWebkitTransitionProperty;
-        break;
+        return CSSPropertyWebkitTransitionProperty;
     case CSSPropertyTransitionTimingFunction:
-        propertyId = CSSPropertyWebkitTransitionTimingFunction;
-        break;
+        return CSSPropertyWebkitTransitionTimingFunction;
     case CSSPropertyTransition:
-        propertyId = CSSPropertyWebkitTransition;
-        break;
+        return CSSPropertyWebkitTransition;
     case CSSPropertyWebkitTransitionDelay:
-        propertyId = CSSPropertyTransitionDelay;
-        break;
+        return CSSPropertyTransitionDelay;
     case CSSPropertyWebkitTransitionDuration:
-        propertyId = CSSPropertyTransitionDuration;
-        break;
+        return CSSPropertyTransitionDuration;
     case CSSPropertyWebkitTransitionProperty:
-        propertyId = CSSPropertyTransitionProperty;
-        break;
+        return CSSPropertyTransitionProperty;
     case CSSPropertyWebkitTransitionTimingFunction:
-        propertyId = CSSPropertyTransitionTimingFunction;
-        break;
+        return CSSPropertyTransitionTimingFunction;
     case CSSPropertyWebkitTransition:
-        propertyId = CSSPropertyTransition;
-        break;
+        return CSSPropertyTransition;
     default:
-        propertyId = propId;
-        break;
+        return propertyID;
     }
-    ASSERT(propertyId != CSSPropertyInvalid);
-    return propertyId;
 }
 
 } // namespace WebCore

Modified: trunk/Source/WebCore/css/CSSPropertyNames.in (176049 => 176050)


--- trunk/Source/WebCore/css/CSSPropertyNames.in	2014-11-13 00:27:17 UTC (rev 176049)
+++ trunk/Source/WebCore/css/CSSPropertyNames.in	2014-11-13 01:23:15 UTC (rev 176050)
@@ -86,6 +86,15 @@
 -webkit-ruby-position [Inherited, NewStyleBuilder, TypeName=RubyPosition]
 
 // The remaining properties are listed in alphabetical order
+animation
+animation-delay
+animation-direction
+animation-duration
+animation-fill-mode
+animation-iteration-count
+animation-name
+animation-play-state
+animation-timing-function
 background
 background-attachment
 background-blend-mode

Modified: trunk/Source/WebCore/css/DeprecatedStyleBuilder.cpp (176049 => 176050)


--- trunk/Source/WebCore/css/DeprecatedStyleBuilder.cpp	2014-11-13 00:27:17 UTC (rev 176049)
+++ trunk/Source/WebCore/css/DeprecatedStyleBuilder.cpp	2014-11-13 01:23:15 UTC (rev 176050)
@@ -1492,6 +1492,16 @@
     setPropertyHandler(CSSPropertyWebkitTextUnderlinePosition, ApplyPropertyTextUnderlinePosition::createHandler());
     setPropertyHandler(CSSPropertyTextRendering, ApplyPropertyFont<TextRenderingMode, &FontDescription::textRenderingMode, &FontDescription::setTextRenderingMode, AutoTextRendering>::createHandler());
     setPropertyHandler(CSSPropertyVerticalAlign, ApplyPropertyVerticalAlign::createHandler());
+
+    setPropertyHandler(CSSPropertyAnimationDelay, ApplyPropertyAnimation<double, &Animation::delay, &Animation::setDelay, &Animation::isDelaySet, &Animation::clearDelay, &Animation::initialAnimationDelay, &CSSToStyleMap::mapAnimationDelay, &RenderStyle::accessAnimations, &RenderStyle::animations>::createHandler());
+    setPropertyHandler(CSSPropertyAnimationDirection, ApplyPropertyAnimation<Animation::AnimationDirection, &Animation::direction, &Animation::setDirection, &Animation::isDirectionSet, &Animation::clearDirection, &Animation::initialAnimationDirection, &CSSToStyleMap::mapAnimationDirection, &RenderStyle::accessAnimations, &RenderStyle::animations>::createHandler());
+    setPropertyHandler(CSSPropertyAnimationDuration, ApplyPropertyAnimation<double, &Animation::duration, &Animation::setDuration, &Animation::isDurationSet, &Animation::clearDuration, &Animation::initialAnimationDuration, &CSSToStyleMap::mapAnimationDuration, &RenderStyle::accessAnimations, &RenderStyle::animations>::createHandler());
+    setPropertyHandler(CSSPropertyAnimationFillMode, ApplyPropertyAnimation<unsigned, &Animation::fillMode, &Animation::setFillMode, &Animation::isFillModeSet, &Animation::clearFillMode, &Animation::initialAnimationFillMode, &CSSToStyleMap::mapAnimationFillMode, &RenderStyle::accessAnimations, &RenderStyle::animations>::createHandler());
+    setPropertyHandler(CSSPropertyAnimationIterationCount, ApplyPropertyAnimation<double, &Animation::iterationCount, &Animation::setIterationCount, &Animation::isIterationCountSet, &Animation::clearIterationCount, &Animation::initialAnimationIterationCount, &CSSToStyleMap::mapAnimationIterationCount, &RenderStyle::accessAnimations, &RenderStyle::animations>::createHandler());
+    setPropertyHandler(CSSPropertyAnimationName, ApplyPropertyAnimation<const String&, &Animation::name, &Animation::setName, &Animation::isNameSet, &Animation::clearName, &Animation::initialAnimationName, &CSSToStyleMap::mapAnimationName, &RenderStyle::accessAnimations, &RenderStyle::animations>::createHandler());
+    setPropertyHandler(CSSPropertyAnimationPlayState, ApplyPropertyAnimation<EAnimPlayState, &Animation::playState, &Animation::setPlayState, &Animation::isPlayStateSet, &Animation::clearPlayState, &Animation::initialAnimationPlayState, &CSSToStyleMap::mapAnimationPlayState, &RenderStyle::accessAnimations, &RenderStyle::animations>::createHandler());
+    setPropertyHandler(CSSPropertyAnimationTimingFunction, ApplyPropertyAnimation<const PassRefPtr<TimingFunction>, &Animation::timingFunction, &Animation::setTimingFunction, &Animation::isTimingFunctionSet, &Animation::clearTimingFunction, &Animation::initialAnimationTimingFunction, &CSSToStyleMap::mapAnimationTimingFunction, &RenderStyle::accessAnimations, &RenderStyle::animations>::createHandler());
+
     setPropertyHandler(CSSPropertyWebkitAnimationDelay, ApplyPropertyAnimation<double, &Animation::delay, &Animation::setDelay, &Animation::isDelaySet, &Animation::clearDelay, &Animation::initialAnimationDelay, &CSSToStyleMap::mapAnimationDelay, &RenderStyle::accessAnimations, &RenderStyle::animations>::createHandler());
     setPropertyHandler(CSSPropertyWebkitAnimationDirection, ApplyPropertyAnimation<Animation::AnimationDirection, &Animation::direction, &Animation::setDirection, &Animation::isDirectionSet, &Animation::clearDirection, &Animation::initialAnimationDirection, &CSSToStyleMap::mapAnimationDirection, &RenderStyle::accessAnimations, &RenderStyle::animations>::createHandler());
     setPropertyHandler(CSSPropertyWebkitAnimationDuration, ApplyPropertyAnimation<double, &Animation::duration, &Animation::setDuration, &Animation::isDurationSet, &Animation::clearDuration, &Animation::initialAnimationDuration, &CSSToStyleMap::mapAnimationDuration, &RenderStyle::accessAnimations, &RenderStyle::animations>::createHandler());

Modified: trunk/Source/WebCore/css/StyleProperties.cpp (176049 => 176050)


--- trunk/Source/WebCore/css/StyleProperties.cpp	2014-11-13 00:27:17 UTC (rev 176049)
+++ trunk/Source/WebCore/css/StyleProperties.cpp	2014-11-13 01:23:15 UTC (rev 176050)
@@ -125,6 +125,8 @@
 
     // Shorthand and 4-values properties
     switch (propertyID) {
+    case CSSPropertyAnimation:
+        return getLayeredShorthandValue(animationShorthand());
     case CSSPropertyBorderSpacing:
         return borderSpacingValue(borderSpacingShorthand());
     case CSSPropertyBackgroundPosition:
@@ -796,6 +798,15 @@
         String value;
 
         switch (propertyID) {
+        case CSSPropertyAnimationName:
+        case CSSPropertyAnimationDuration:
+        case CSSPropertyAnimationTimingFunction:
+        case CSSPropertyAnimationDelay:
+        case CSSPropertyAnimationIterationCount:
+        case CSSPropertyAnimationDirection:
+        case CSSPropertyAnimationFillMode:
+            shorthandPropertyID = CSSPropertyAnimation;
+            break;
         case CSSPropertyBackgroundPositionX:
             positionXPropertyIndex = n;
             continue;

Modified: trunk/Source/WebCore/css/StylePropertyShorthand.cpp (176049 => 176050)


--- trunk/Source/WebCore/css/StylePropertyShorthand.cpp	2014-11-13 00:27:17 UTC (rev 176049)
+++ trunk/Source/WebCore/css/StylePropertyShorthand.cpp	2014-11-13 01:23:15 UTC (rev 176050)
@@ -255,6 +255,20 @@
     return StylePropertyShorthand(CSSPropertyTransition, transitionProperties, WTF_ARRAY_LENGTH(transitionProperties));
 }
 
+StylePropertyShorthand animationShorthand()
+{
+    static const CSSPropertyID animationProperties[] = {
+        CSSPropertyAnimationName,
+        CSSPropertyAnimationDuration,
+        CSSPropertyAnimationTimingFunction,
+        CSSPropertyAnimationDelay,
+        CSSPropertyAnimationIterationCount,
+        CSSPropertyAnimationDirection,
+        CSSPropertyAnimationFillMode
+    };
+    return StylePropertyShorthand(CSSPropertyAnimation, animationProperties, WTF_ARRAY_LENGTH(animationProperties));
+}
+
 StylePropertyShorthand webkitAnimationShorthand()
 {
     static const CSSPropertyID animationProperties[] = {
@@ -269,7 +283,7 @@
     return StylePropertyShorthand(CSSPropertyWebkitAnimation, animationProperties, WTF_ARRAY_LENGTH(animationProperties));
 }
 
-StylePropertyShorthand webkitAnimationShorthandForParsing()
+StylePropertyShorthand animationShorthandForParsing(CSSPropertyID propId)
 {
     // When we parse the animation shorthand we need to look for animation-name
     // last because otherwise it might match against the keywords for fill mode,
@@ -281,6 +295,16 @@
     // And in the spec (editor's draft) at:
     // http://dev.w3.org/csswg/css3-animations/#animation-shorthand-property
     static const CSSPropertyID animationPropertiesForParsing[] = {
+        CSSPropertyAnimationDuration,
+        CSSPropertyAnimationTimingFunction,
+        CSSPropertyAnimationDelay,
+        CSSPropertyAnimationIterationCount,
+        CSSPropertyAnimationDirection,
+        CSSPropertyAnimationFillMode,
+        CSSPropertyAnimationName
+    };
+
+    static const CSSPropertyID prefixedAnimationPropertiesForParsing[] = {
         CSSPropertyWebkitAnimationDuration,
         CSSPropertyWebkitAnimationTimingFunction,
         CSSPropertyWebkitAnimationDelay,
@@ -290,7 +314,9 @@
         CSSPropertyWebkitAnimationName
     };
 
-    return StylePropertyShorthand(CSSPropertyWebkitAnimation, animationPropertiesForParsing, WTF_ARRAY_LENGTH(animationPropertiesForParsing));
+    if (propId == CSSPropertyAnimation)
+        return StylePropertyShorthand(CSSPropertyAnimation, animationPropertiesForParsing, WTF_ARRAY_LENGTH(animationPropertiesForParsing));
+    return StylePropertyShorthand(CSSPropertyWebkitAnimation, prefixedAnimationPropertiesForParsing, WTF_ARRAY_LENGTH(prefixedAnimationPropertiesForParsing));
 }
 
 StylePropertyShorthand webkitBorderAfterShorthand()
@@ -515,6 +541,8 @@
 StylePropertyShorthand shorthandForProperty(CSSPropertyID propertyID)
 {
     switch (propertyID) {
+    case CSSPropertyAnimation:
+        return animationShorthand();
     case CSSPropertyBackground:
         return backgroundShorthand();
     case CSSPropertyBackgroundPosition:
@@ -655,6 +683,14 @@
 Vector<StylePropertyShorthand> matchingShorthandsForLonghand(CSSPropertyID propertyID)
 {
     switch (propertyID) {
+    case CSSPropertyAnimationName:
+    case CSSPropertyAnimationDuration:
+    case CSSPropertyAnimationTimingFunction:
+    case CSSPropertyAnimationDelay:
+    case CSSPropertyAnimationIterationCount:
+    case CSSPropertyAnimationDirection:
+    case CSSPropertyAnimationFillMode:
+        return makeVector(animationShorthand());
     case CSSPropertyBackgroundImage:
     case CSSPropertyBackgroundSize:
     case CSSPropertyBackgroundAttachment:

Modified: trunk/Source/WebCore/css/StylePropertyShorthand.h (176049 => 176050)


--- trunk/Source/WebCore/css/StylePropertyShorthand.h	2014-11-13 00:27:17 UTC (rev 176049)
+++ trunk/Source/WebCore/css/StylePropertyShorthand.h	2014-11-13 01:23:15 UTC (rev 176050)
@@ -65,6 +65,8 @@
     CSSPropertyID m_shorthandID;
 };
 
+StylePropertyShorthand animationShorthand();
+StylePropertyShorthand animationShorthandForParsing(CSSPropertyID);
 StylePropertyShorthand backgroundShorthand();
 StylePropertyShorthand backgroundPositionShorthand();
 StylePropertyShorthand backgroundRepeatShorthand();
@@ -91,7 +93,6 @@
 StylePropertyShorthand paddingShorthand();
 StylePropertyShorthand transitionShorthand();
 StylePropertyShorthand webkitAnimationShorthand();
-StylePropertyShorthand webkitAnimationShorthandForParsing();
 StylePropertyShorthand webkitBorderAfterShorthand();
 StylePropertyShorthand webkitBorderBeforeShorthand();
 StylePropertyShorthand webkitBorderEndShorthand();

Modified: trunk/Source/WebCore/css/StyleResolver.cpp (176049 => 176050)


--- trunk/Source/WebCore/css/StyleResolver.cpp	2014-11-13 00:27:17 UTC (rev 176049)
+++ trunk/Source/WebCore/css/StyleResolver.cpp	2014-11-13 01:23:15 UTC (rev 176050)
@@ -841,7 +841,7 @@
         applyProperty(CSSPropertyLineHeight, state.lineHeightValue());
 
     // Now do rest of the properties.
-    applyCascadedProperties(cascade, CSSPropertyBackground, lastCSSProperty);
+    applyCascadedProperties(cascade, CSSPropertyAnimation, lastCSSProperty);
 
     // If our font got dirtied by one of the non-essential font props,
     // go ahead and update it a second time.
@@ -858,7 +858,7 @@
         CSSPropertyID property = keyframe->properties().propertyAt(i).id();
         // Timing-function within keyframes is special, because it is not animated; it just
         // describes the timing function between this keyframe and the next.
-        if (property != CSSPropertyWebkitAnimationTimingFunction)
+        if (property != CSSPropertyWebkitAnimationTimingFunction && property != CSSPropertyAnimationTimingFunction)
             keyframeValue.addProperty(property);
     }
 
@@ -1011,7 +1011,7 @@
     if (m_state.lineHeightValue())
         applyProperty(CSSPropertyLineHeight, m_state.lineHeightValue());
 
-    applyCascadedProperties(cascade, CSSPropertyBackground, lastCSSProperty);
+    applyCascadedProperties(cascade, CSSPropertyAnimation, lastCSSProperty);
 
     cascade.applyDeferredProperties(*this);
 
@@ -1716,7 +1716,7 @@
         applyCascadedProperties(cascade, firstCSSProperty, CSSPropertyLineHeight);
     
         updateFont();
-        applyCascadedProperties(cascade, CSSPropertyBackground, lastCSSProperty);
+        applyCascadedProperties(cascade, CSSPropertyAnimation, lastCSSProperty);
 
         state.cacheBorderAndBackground();
     }
@@ -1754,7 +1754,7 @@
         return applyMatchedProperties(matchResult, element, DoNotUseMatchedPropertiesCache);
 
     // Apply properties that no other properties depend on.
-    applyCascadedProperties(cascade, CSSPropertyBackground, lastCSSProperty);
+    applyCascadedProperties(cascade, CSSPropertyAnimation, lastCSSProperty);
 
     // Finally, some properties must be applied in the order they were parsed.
     // There are some CSS properties that affect the same RenderStyle values,
@@ -2346,6 +2346,7 @@
         }
         return;
 
+    case CSSPropertyAnimation:
     case CSSPropertyBackground:
     case CSSPropertyBackgroundPosition:
     case CSSPropertyBackgroundRepeat:
@@ -2955,6 +2956,14 @@
     }
     
     // These properties are aliased and DeprecatedStyleBuilder already applied the property on the prefixed version.
+    case CSSPropertyAnimationDelay:
+    case CSSPropertyAnimationDirection:
+    case CSSPropertyAnimationDuration:
+    case CSSPropertyAnimationFillMode:
+    case CSSPropertyAnimationName:
+    case CSSPropertyAnimationPlayState:
+    case CSSPropertyAnimationIterationCount:
+    case CSSPropertyAnimationTimingFunction:
     case CSSPropertyTransitionDelay:
     case CSSPropertyTransitionDuration:
     case CSSPropertyTransitionProperty:
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to