| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2004, 2005 Nikolas Zimmermann <zimmermann@kde.org> | 2 * Copyright (C) 2004, 2005 Nikolas Zimmermann <zimmermann@kde.org> |
| 3 * Copyright (C) 2004, 2005, 2006 Rob Buis <buis@kde.org> | 3 * Copyright (C) 2004, 2005, 2006 Rob Buis <buis@kde.org> |
| 4 * Copyright (C) 2008 Apple Inc. All rights reserved. | 4 * Copyright (C) 2008 Apple Inc. All rights reserved. |
| 5 * Copyright (C) Research In Motion Limited 2011. All rights reserved. | 5 * Copyright (C) Research In Motion Limited 2011. All rights reserved. |
| 6 * | 6 * |
| 7 * This library is free software; you can redistribute it and/or | 7 * This library is free software; you can redistribute it and/or |
| 8 * modify it under the terms of the GNU Library General Public | 8 * modify it under the terms of the GNU Library General Public |
| 9 * License as published by the Free Software Foundation; either | 9 * License as published by the Free Software Foundation; either |
| 10 * version 2 of the License, or (at your option) any later version. | 10 * version 2 of the License, or (at your option) any later version. |
| (...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 104 | 104 |
| 105 ASSERT(percentage >= 0 && percentage <= 1); | 105 ASSERT(percentage >= 0 && percentage <= 1); |
| 106 ASSERT(m_animatedPropertyType != AnimatedTransformList || hasTagName(SVGName
s::animateTransformTag)); | 106 ASSERT(m_animatedPropertyType != AnimatedTransformList || hasTagName(SVGName
s::animateTransformTag)); |
| 107 ASSERT(m_animatedPropertyType != AnimatedUnknown); | 107 ASSERT(m_animatedPropertyType != AnimatedUnknown); |
| 108 ASSERT(m_animator); | 108 ASSERT(m_animator); |
| 109 ASSERT(m_animator->type() == m_animatedPropertyType); | 109 ASSERT(m_animator->type() == m_animatedPropertyType); |
| 110 ASSERT(m_fromType); | 110 ASSERT(m_fromType); |
| 111 ASSERT(m_fromType->type() == m_animatedPropertyType); | 111 ASSERT(m_fromType->type() == m_animatedPropertyType); |
| 112 ASSERT(m_toType); | 112 ASSERT(m_toType); |
| 113 | 113 |
| 114 ASSERT(resultElement->hasTagName(SVGNames::animateTag) | 114 SVGAnimateElement* resultAnimationElement = toSVGAnimateElement(resultElemen
t); |
| 115 || resultElement->hasTagName(SVGNames::animateColorTag) | |
| 116 || resultElement->hasTagName(SVGNames::animateTransformTag) | |
| 117 || resultElement->hasTagName(SVGNames::setTag)); | |
| 118 | |
| 119 SVGAnimateElement* resultAnimationElement = static_cast<SVGAnimateElement*>(
resultElement); | |
| 120 ASSERT(resultAnimationElement->m_animatedType); | 115 ASSERT(resultAnimationElement->m_animatedType); |
| 121 ASSERT(resultAnimationElement->m_animatedPropertyType == m_animatedPropertyT
ype); | 116 ASSERT(resultAnimationElement->m_animatedPropertyType == m_animatedPropertyT
ype); |
| 122 | 117 |
| 123 if (hasTagName(SVGNames::setTag)) | 118 if (hasTagName(SVGNames::setTag)) |
| 124 percentage = 1; | 119 percentage = 1; |
| 125 | 120 |
| 126 if (calcMode() == CalcModeDiscrete) | 121 if (calcMode() == CalcModeDiscrete) |
| 127 percentage = percentage < 0.5 ? 0 : 1; | 122 percentage = percentage < 0.5 ? 0 : 1; |
| 128 | 123 |
| 129 // Target element might have changed. | 124 // Target element might have changed. |
| (...skipping 295 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 425 | 420 |
| 426 SVGAnimatedTypeAnimator* SVGAnimateElement::ensureAnimator() | 421 SVGAnimatedTypeAnimator* SVGAnimateElement::ensureAnimator() |
| 427 { | 422 { |
| 428 if (!m_animator) | 423 if (!m_animator) |
| 429 m_animator = SVGAnimatorFactory::create(this, targetElement(), m_animate
dPropertyType); | 424 m_animator = SVGAnimatorFactory::create(this, targetElement(), m_animate
dPropertyType); |
| 430 ASSERT(m_animatedPropertyType == m_animator->type()); | 425 ASSERT(m_animatedPropertyType == m_animator->type()); |
| 431 return m_animator.get(); | 426 return m_animator.get(); |
| 432 } | 427 } |
| 433 | 428 |
| 434 } | 429 } |
| OLD | NEW |