Unprefix -webkit-cross-fade()
authorsimon.fraser@apple.com <simon.fraser@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 13 May 2016 22:40:52 +0000 (22:40 +0000)
committersimon.fraser@apple.com <simon.fraser@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 13 May 2016 22:40:52 +0000 (22:40 +0000)
commite8953a20be6e5983c9c7b3963b31269a35c84caf
treeb045049066efc6182242e0fc4d3d76ffaccc6696
parent917348e95a3c1cc9e3dee0effd86dbe9fffb46dc
Unprefix -webkit-cross-fade()
https://bugs.webkit.org/show_bug.cgi?id=157632

Reviewed by Darin Adler.
Source/WebCore:

Support unprefixed cross-fade() in addition to the prefixed value when parsing,
and have computed style round-trip the correct one.

If computed style is queried during an image transition, return an unprefixed
cross-fade(). If blending cross-fade values, only return the prefixed function if
both inputs are prefixed.

Tested by modified and existing tests.

* css/CSSCrossfadeValue.cpp:
(WebCore::CSSCrossfadeValue::customCSSText):
(WebCore::CSSCrossfadeValue::blend):
* css/CSSCrossfadeValue.h:
(WebCore::CSSCrossfadeValue::create):
(WebCore::CSSCrossfadeValue::isPrefixed):
(WebCore::CSSCrossfadeValue::CSSCrossfadeValue):
* css/CSSParser.cpp:
(WebCore::CSSParser::isGeneratedImageValue):
(WebCore::CSSParser::parseGeneratedImage):
(WebCore::CSSParser::parseCrossfade):
* css/CSSParser.h:

Source/WebInspectorUI:

* UserInterface/Models/CSSKeywordCompletions.js:

LayoutTests:

* animations/cross-fade-background-image-expected.html:
* animations/cross-fade-background-image.html:
* animations/cross-fade-border-image-source.html:
* animations/cross-fade-list-style-image.html:
* animations/cross-fade-webkit-mask-box-image.html:
* animations/cross-fade-webkit-mask-image.html:
* animations/resources/animation-test-helpers.js:
(parseCSSImage):
(parseCrossFade):
(compareCSSImages):
* fast/css/getComputedStyle/computed-style-cross-fade-expected.txt:
* fast/css/getComputedStyle/computed-style-cross-fade.html:
* transitions/resources/transition-test-helpers.js:
(parseCrossFade):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@200888 268f45cc-cd09-0410-ab3c-d52691b4dbfc
18 files changed:
LayoutTests/ChangeLog
LayoutTests/animations/cross-fade-background-image-expected.html
LayoutTests/animations/cross-fade-background-image.html
LayoutTests/animations/cross-fade-border-image-source.html
LayoutTests/animations/cross-fade-list-style-image.html
LayoutTests/animations/cross-fade-webkit-mask-box-image.html
LayoutTests/animations/cross-fade-webkit-mask-image.html
LayoutTests/animations/resources/animation-test-helpers.js
LayoutTests/fast/css/getComputedStyle/computed-style-cross-fade-expected.txt
LayoutTests/fast/css/getComputedStyle/computed-style-cross-fade.html
LayoutTests/transitions/resources/transition-test-helpers.js
Source/WebCore/ChangeLog
Source/WebCore/css/CSSCrossfadeValue.cpp
Source/WebCore/css/CSSCrossfadeValue.h
Source/WebCore/css/CSSParser.cpp
Source/WebCore/css/CSSParser.h
Source/WebInspectorUI/ChangeLog
Source/WebInspectorUI/UserInterface/Models/CSSKeywordCompletions.js