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

Side by Side Diff: Source/core/svg/SVGAnimatedTypeAnimator.cpp

Issue 268223003: Move InvalidationGuard/InstanceUpdateBlocker out of SVGElementInstance (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Perform the renames Created 6 years, 7 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 unified diff | Download patch
« no previous file with comments | « Source/core/svg/SVGAnimateElement.cpp ('k') | Source/core/svg/SVGCircleElement.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) Research In Motion Limited 2011-2012. All rights reserved. 2 * Copyright (C) Research In Motion Limited 2011-2012. All rights reserved.
3 * Copyright (C) 2013 Samsung Electronics. All rights reserved. 3 * Copyright (C) 2013 Samsung Electronics. All rights reserved.
4 * 4 *
5 * This library is free software; you can redistribute it and/or 5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Library General Public 6 * modify it under the terms of the GNU Library General Public
7 * License as published by the Free Software Foundation; either 7 * License as published by the Free Software Foundation; either
8 * version 2 of the License, or (at your option) any later version. 8 * version 2 of the License, or (at your option) any later version.
9 * 9 *
10 * This library is distributed in the hope that it will be useful, 10 * This library is distributed in the hope that it will be useful,
(...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after
189 RefPtr<SVGPropertyBase> animatedValue = m_animatedProperty->createAnimatedVa lue(); 189 RefPtr<SVGPropertyBase> animatedValue = m_animatedProperty->createAnimatedVa lue();
190 ASSERT(animatedValue->type() == m_type); 190 ASSERT(animatedValue->type() == m_type);
191 setAnimatedValueOnAllTargetProperties(list, m_animatedProperty->attributeNam e(), animatedValue); 191 setAnimatedValueOnAllTargetProperties(list, m_animatedProperty->attributeNam e(), animatedValue);
192 192
193 return animatedValue.release(); 193 return animatedValue.release();
194 } 194 }
195 195
196 PassRefPtr<SVGPropertyBase> SVGAnimatedTypeAnimator::startAnimValAnimation(const Vector<SVGElement*>& list) 196 PassRefPtr<SVGPropertyBase> SVGAnimatedTypeAnimator::startAnimValAnimation(const Vector<SVGElement*>& list)
197 { 197 {
198 ASSERT(isAnimatingSVGDom()); 198 ASSERT(isAnimatingSVGDom());
199 SVGElementInstance::InstanceUpdateBlocker blocker(m_contextElement); 199 SVGElement::InstanceUpdateBlocker blocker(m_contextElement);
200 200
201 invokeMethodOnAllTargetProperties(list, m_animatedProperty->attributeName(), &SVGAnimatedPropertyBase::animationStarted); 201 invokeMethodOnAllTargetProperties(list, m_animatedProperty->attributeName(), &SVGAnimatedPropertyBase::animationStarted);
202 202
203 return resetAnimation(list); 203 return resetAnimation(list);
204 } 204 }
205 205
206 void SVGAnimatedTypeAnimator::stopAnimValAnimation(const Vector<SVGElement*>& li st) 206 void SVGAnimatedTypeAnimator::stopAnimValAnimation(const Vector<SVGElement*>& li st)
207 { 207 {
208 ASSERT(isAnimatingSVGDom()); 208 ASSERT(isAnimatingSVGDom());
209 SVGElementInstance::InstanceUpdateBlocker blocker(m_contextElement); 209 SVGElement::InstanceUpdateBlocker blocker(m_contextElement);
210 210
211 invokeMethodOnAllTargetProperties(list, m_animatedProperty->attributeName(), &SVGAnimatedPropertyBase::animationEnded); 211 invokeMethodOnAllTargetProperties(list, m_animatedProperty->attributeName(), &SVGAnimatedPropertyBase::animationEnded);
212 } 212 }
213 213
214 PassRefPtr<SVGPropertyBase> SVGAnimatedTypeAnimator::resetAnimValToBaseVal(const Vector<SVGElement*>& list) 214 PassRefPtr<SVGPropertyBase> SVGAnimatedTypeAnimator::resetAnimValToBaseVal(const Vector<SVGElement*>& list)
215 { 215 {
216 SVGElementInstance::InstanceUpdateBlocker blocker(m_contextElement); 216 SVGElement::InstanceUpdateBlocker blocker(m_contextElement);
217 217
218 return resetAnimation(list); 218 return resetAnimation(list);
219 } 219 }
220 220
221 class ParsePropertyFromString { 221 class ParsePropertyFromString {
222 public: 222 public:
223 explicit ParsePropertyFromString(SVGAnimatedTypeAnimator* animator) 223 explicit ParsePropertyFromString(SVGAnimatedTypeAnimator* animator)
224 : m_animator(animator) 224 : m_animator(animator)
225 { 225 {
226 } 226 }
(...skipping 28 matching lines...) Expand all
255 float SVGAnimatedTypeAnimator::calculateDistance(const String& fromString, const String& toString) 255 float SVGAnimatedTypeAnimator::calculateDistance(const String& fromString, const String& toString)
256 { 256 {
257 ASSERT(m_animationElement); 257 ASSERT(m_animationElement);
258 ASSERT(m_contextElement); 258 ASSERT(m_contextElement);
259 RefPtr<SVGPropertyBase> fromValue = createPropertyForAnimation(fromString); 259 RefPtr<SVGPropertyBase> fromValue = createPropertyForAnimation(fromString);
260 RefPtr<SVGPropertyBase> toValue = createPropertyForAnimation(toString); 260 RefPtr<SVGPropertyBase> toValue = createPropertyForAnimation(toString);
261 return fromValue->calculateDistance(toValue, m_contextElement); 261 return fromValue->calculateDistance(toValue, m_contextElement);
262 } 262 }
263 263
264 } 264 }
OLDNEW
« no previous file with comments | « Source/core/svg/SVGAnimateElement.cpp ('k') | Source/core/svg/SVGCircleElement.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698