Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(579)

Unified Diff: Source/core/svg/SVGAnimatedRect.cpp

Issue 19096011: Get rid of SVGRect special case from the bindings generator (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase on master Created 7 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/svg/SVGAnimatedRect.h ('k') | Source/core/svg/SVGAnimatedType.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/svg/SVGAnimatedRect.cpp
diff --git a/Source/core/svg/SVGAnimatedRect.cpp b/Source/core/svg/SVGAnimatedRect.cpp
index 8301cc64312dac11287fcf196fc9d3c7a27dbcc9..6c74641b26c7a9837e09930a6e9516f1362c3bdc 100644
--- a/Source/core/svg/SVGAnimatedRect.cpp
+++ b/Source/core/svg/SVGAnimatedRect.cpp
@@ -33,7 +33,7 @@ SVGAnimatedRectAnimator::SVGAnimatedRectAnimator(SVGAnimationElement* animationE
PassOwnPtr<SVGAnimatedType> SVGAnimatedRectAnimator::constructFromString(const String& string)
{
- OwnPtr<SVGAnimatedType> animatedType = SVGAnimatedType::createRect(new FloatRect);
+ OwnPtr<SVGAnimatedType> animatedType = SVGAnimatedType::createRect(new SVGRect);
parseRect(string, animatedType->rect());
return animatedType.release();
}
@@ -76,10 +76,10 @@ void SVGAnimatedRectAnimator::calculateAnimatedValue(float percentage, unsigned
ASSERT(m_animationElement);
ASSERT(m_contextElement);
- const FloatRect& fromRect = m_animationElement->animationMode() == ToAnimation ? animated->rect() : from->rect();
- const FloatRect& toRect = to->rect();
- const FloatRect& toAtEndOfDurationRect = toAtEndOfDuration->rect();
- FloatRect& animatedRect = animated->rect();
+ const SVGRect& fromRect = m_animationElement->animationMode() == ToAnimation ? animated->rect() : from->rect();
+ const SVGRect& toRect = to->rect();
+ const SVGRect& toAtEndOfDurationRect = toAtEndOfDuration->rect();
+ SVGRect& animatedRect = animated->rect();
float animatedX = animatedRect.x();
float animatedY = animatedRect.y();
@@ -90,7 +90,7 @@ void SVGAnimatedRectAnimator::calculateAnimatedValue(float percentage, unsigned
m_animationElement->animateAdditiveNumber(percentage, repeatCount, fromRect.width(), toRect.width(), toAtEndOfDurationRect.width(), animatedWidth);
m_animationElement->animateAdditiveNumber(percentage, repeatCount, fromRect.height(), toRect.height(), toAtEndOfDurationRect.height(), animatedHeight);
- animatedRect = FloatRect(animatedX, animatedY, animatedWidth, animatedHeight);
+ animatedRect = SVGRect(animatedX, animatedY, animatedWidth, animatedHeight);
}
float SVGAnimatedRectAnimator::calculateDistance(const String&, const String&)
« no previous file with comments | « Source/core/svg/SVGAnimatedRect.h ('k') | Source/core/svg/SVGAnimatedType.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698