| Index: Source/core/platform/graphics/GraphicsLayerAnimation.cpp
|
| diff --git a/Source/core/platform/graphics/GraphicsLayerAnimation.cpp b/Source/core/platform/graphics/GraphicsLayerAnimation.cpp
|
| index dab1ac97407c347c74a0c800bd21686a666f7a14..acf95fab69f4ce3c55bfdc0da57d4f8c46ffb276 100644
|
| --- a/Source/core/platform/graphics/GraphicsLayerAnimation.cpp
|
| +++ b/Source/core/platform/graphics/GraphicsLayerAnimation.cpp
|
| @@ -73,16 +73,16 @@ static FilterOperations applyFilterAnimation(const FilterOperations* from, const
|
| return result;
|
| }
|
|
|
| -static bool shouldReverseAnimationValue(Animation::AnimationDirection direction, int loopCount)
|
| +static bool shouldReverseAnimationValue(PrimitiveAnimation::AnimationDirection direction, int loopCount)
|
| {
|
| - if (((direction == Animation::AnimationDirectionAlternate) && (loopCount & 1))
|
| - || ((direction == Animation::AnimationDirectionAlternateReverse) && !(loopCount & 1))
|
| - || direction == Animation::AnimationDirectionReverse)
|
| + if (((direction == PrimitiveAnimation::AnimationDirectionAlternate) && (loopCount & 1))
|
| + || ((direction == PrimitiveAnimation::AnimationDirectionAlternateReverse) && !(loopCount & 1))
|
| + || direction == PrimitiveAnimation::AnimationDirectionReverse)
|
| return true;
|
| return false;
|
| }
|
|
|
| -static double normalizedAnimationValue(double runningTime, double duration, Animation::AnimationDirection direction, double iterationCount)
|
| +static double normalizedAnimationValue(double runningTime, double duration, PrimitiveAnimation::AnimationDirection direction, double iterationCount)
|
| {
|
| if (!duration)
|
| return 0;
|
| @@ -96,11 +96,11 @@ static double normalizedAnimationValue(double runningTime, double duration, Anim
|
| return shouldReverseAnimationValue(direction, loopCount) ? 1 - normalized : normalized;
|
| }
|
|
|
| -static double normalizedAnimationValueForFillsForwards(double iterationCount, Animation::AnimationDirection direction)
|
| +static double normalizedAnimationValueForFillsForwards(double iterationCount, PrimitiveAnimation::AnimationDirection direction)
|
| {
|
| - if (direction == Animation::AnimationDirectionNormal)
|
| + if (direction == PrimitiveAnimation::AnimationDirectionNormal)
|
| return 1;
|
| - if (direction == Animation::AnimationDirectionReverse)
|
| + if (direction == PrimitiveAnimation::AnimationDirectionReverse)
|
| return 0;
|
| return shouldReverseAnimationValue(direction, iterationCount) ? 1 : 0;
|
| }
|
| @@ -200,7 +200,7 @@ static TransformationMatrix applyTransformAnimation(const TransformOperations* f
|
| return matrix;
|
| }
|
|
|
| -static const TimingFunction* timingFunctionForAnimationValue(const AnimationValue* animValue, const Animation* anim)
|
| +static const TimingFunction* timingFunctionForAnimationValue(const AnimationValue* animValue, const PrimitiveAnimation* anim)
|
| {
|
| if (animValue->timingFunction())
|
| return animValue->timingFunction();
|
| @@ -210,10 +210,10 @@ static const TimingFunction* timingFunctionForAnimationValue(const AnimationValu
|
| return CubicBezierTimingFunction::defaultTimingFunction();
|
| }
|
|
|
| -GraphicsLayerAnimation::GraphicsLayerAnimation(const String& name, const KeyframeValueList& keyframes, const IntSize& boxSize, const Animation* animation, double startTime, bool listsMatch)
|
| +GraphicsLayerAnimation::GraphicsLayerAnimation(const String& name, const KeyframeValueList& keyframes, const IntSize& boxSize, const PrimitiveAnimation* animation, double startTime, bool listsMatch)
|
| : m_keyframes(keyframes)
|
| , m_boxSize(boxSize)
|
| - , m_animation(Animation::create(animation))
|
| + , m_animation(PrimitiveAnimation::create(animation))
|
| , m_name(name)
|
| , m_listsMatch(listsMatch)
|
| , m_startTime(startTime)
|
| @@ -276,7 +276,7 @@ void GraphicsLayerAnimation::apply(Client* client)
|
| double totalRunningTime = computeTotalRunningTime();
|
| double normalizedValue = normalizedAnimationValue(totalRunningTime, m_animation->duration(), m_animation->direction(), m_animation->iterationCount());
|
|
|
| - if (m_animation->iterationCount() != Animation::IterationCountInfinite && totalRunningTime >= m_animation->duration() * m_animation->iterationCount()) {
|
| + if (m_animation->iterationCount() != PrimitiveAnimation::IterationCountInfinite && totalRunningTime >= m_animation->duration() * m_animation->iterationCount()) {
|
| setState(StoppedState);
|
| if (m_animation->fillsForwards())
|
| normalizedValue = normalizedAnimationValueForFillsForwards(m_animation->iterationCount(), m_animation->direction());
|
|
|