2011-06-28 Dirk Schulze <krit@webkit.org>
authorkrit@webkit.org <krit@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 29 Jun 2011 06:54:22 +0000 (06:54 +0000)
committerkrit@webkit.org <krit@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 29 Jun 2011 06:54:22 +0000 (06:54 +0000)
commitd8899669ced59484256751f5bf361ed5a4a5c370
tree1b893b0b1aff9c72ea30f8151d0d19e40042af82
parent68341e4b859cf88318295e7a77a682bc710acc70
2011-06-28  Dirk Schulze  <krit@webkit.org>

        Reviewed by Nikolas Zimmermann.

        SVGAnimatedType should support SVGBoolean animation
        https://bugs.webkit.org/show_bug.cgi?id=63529

        Follow up of "SVGAnimation should use direct unit animation for SVGLength": https://bugs.webkit.org/show_bug.cgi?id=61368
        This patch continues the conversion to the new concept of SVGAnimatorFactory with SVGBoolean.

        The new animator does not affect any behavior, since it was animated with SVGAnimatedString before. The new animator is still needed
        to support animVal and baseVal later.

        Test: svg/animations/svgboolean-animation-1.html

        * CMakeLists.txt: Add new file to build system.
        * GNUmakefile.list.am: Ditto.
        * WebCore.gypi: Ditto.
        * WebCore.pro: Ditto.
        * WebCore.xcodeproj/project.pbxproj: Ditto.
        * svg/SVGAllInOne.cpp: Ditto.
        * svg/SVGAnimateElement.cpp: Make use of AnimatedBoolean.
        (WebCore::SVGAnimateElement::determineAnimatedAttributeType):
        (WebCore::SVGAnimateElement::calculateAnimatedValue):
        (WebCore::SVGAnimateElement::calculateFromAndToValues):
        (WebCore::SVGAnimateElement::calculateFromAndByValues):
        (WebCore::SVGAnimateElement::resetToBaseValue):
        (WebCore::SVGAnimateElement::applyResultsToTarget):
        (WebCore::SVGAnimateElement::calculateDistance):
        * svg/SVGAnimatedBoolean.cpp: Added. New animator for SVGBoolean.
        (WebCore::SVGAnimatedBooleanAnimator::SVGAnimatedBooleanAnimator):
        (WebCore::SVGAnimatedBooleanAnimator::constructFromString):
        (WebCore::SVGAnimatedBooleanAnimator::calculateFromAndToValues):
        (WebCore::SVGAnimatedBooleanAnimator::calculateFromAndByValues):
        (WebCore::SVGAnimatedBooleanAnimator::calculateAnimatedValue):
        (WebCore::SVGAnimatedBooleanAnimator::calculateDistance):
        * svg/SVGAnimatedBoolean.h:
        (WebCore::SVGAnimatedBooleanAnimator::~SVGAnimatedBooleanAnimator):
        * svg/SVGAnimatedType.cpp: Use bool for SVGBoolean.
        (WebCore::SVGAnimatedType::~SVGAnimatedType):
        (WebCore::SVGAnimatedType::createBoolean):
        (WebCore::SVGAnimatedType::boolean):
        (WebCore::SVGAnimatedType::valueAsString):
        (WebCore::SVGAnimatedType::setValueAsString):
        * svg/SVGAnimatedType.h:
        * svg/SVGAnimatorFactory.h: New crate function for SVGAnimatedSVGBooleanAnimator.
        (WebCore::SVGAnimatorFactory::create):
2011-06-28  Dirk Schulze  <krit@webkit.org>

        Reviewed by Nikolas Zimmermann.

        SVGAnimatedType should support SVGBoolean animation
        https://bugs.webkit.org/show_bug.cgi?id=63529

        Test animation of SVGBoolean. Add the test to the skip list of wk2.
        Convert animate-number-calcMode-discrete-keyTimes to common style, no change
        on the test itself.

        * platform/mac-wk2/Skipped:
        * svg/animations/animate-number-calcMode-discrete-keyTimes-expected.txt:
        * svg/animations/animate-number-calcMode-discrete-keyTimes.html:
        * svg/animations/script-tests/svgboolean-animation-1.js: Added.
        (sample1):
        (sample2):
        (sample3):
        (executeTest):
        * svg/animations/svgboolean-animation-1-expected.txt: Added.
        * svg/animations/svgboolean-animation-1.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@89993 268f45cc-cd09-0410-ab3c-d52691b4dbfc
20 files changed:
LayoutTests/ChangeLog
LayoutTests/platform/mac-wk2/Skipped
LayoutTests/svg/animations/animate-number-calcMode-discrete-keyTimes-expected.txt
LayoutTests/svg/animations/animate-number-calcMode-discrete-keyTimes.html
LayoutTests/svg/animations/script-tests/svgboolean-animation-1.js [new file with mode: 0644]
LayoutTests/svg/animations/svgboolean-animation-1-expected.txt [new file with mode: 0644]
LayoutTests/svg/animations/svgboolean-animation-1.html [new file with mode: 0644]
Source/WebCore/CMakeLists.txt
Source/WebCore/ChangeLog
Source/WebCore/GNUmakefile.list.am
Source/WebCore/WebCore.gypi
Source/WebCore/WebCore.pro
Source/WebCore/WebCore.xcodeproj/project.pbxproj
Source/WebCore/svg/SVGAllInOne.cpp
Source/WebCore/svg/SVGAnimateElement.cpp
Source/WebCore/svg/SVGAnimatedBoolean.cpp [new file with mode: 0644]
Source/WebCore/svg/SVGAnimatedBoolean.h
Source/WebCore/svg/SVGAnimatedType.cpp
Source/WebCore/svg/SVGAnimatedType.h
Source/WebCore/svg/SVGAnimatorFactory.h