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

Side by Side Diff: third_party/WebKit/Source/core/animation/KeyframeEffect.cpp

Issue 1474263002: Clear SVG Web Animation effects when animations exit their fill phase (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@_svgPathInterpolationType
Patch Set: Check rare data Created 5 years 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 191 matching lines...) Expand 10 before | Expand all | Expand 10 after
202 202
203 void KeyframeEffect::clearEffects() 203 void KeyframeEffect::clearEffects()
204 { 204 {
205 ASSERT(animation()); 205 ASSERT(animation());
206 ASSERT(m_sampledEffect); 206 ASSERT(m_sampledEffect);
207 207
208 m_sampledEffect->clear(); 208 m_sampledEffect->clear();
209 m_sampledEffect = nullptr; 209 m_sampledEffect = nullptr;
210 restartAnimationOnCompositor(); 210 restartAnimationOnCompositor();
211 m_target->setNeedsAnimationStyleRecalc(); 211 m_target->setNeedsAnimationStyleRecalc();
212 if (RuntimeEnabledFeatures::webAnimationsSVGEnabled() && m_target->isSVGElem ent())
213 toSVGElement(*m_target).clearWebAnimatedAttributes();
212 invalidate(); 214 invalidate();
213 } 215 }
214 216
215 void KeyframeEffect::updateChildrenAndEffects() const 217 void KeyframeEffect::updateChildrenAndEffects() const
216 { 218 {
217 if (!m_model) 219 if (!m_model)
218 return; 220 return;
219 if (isInEffect()) 221 if (isInEffect())
220 const_cast<KeyframeEffect*>(this)->applyEffects(); 222 const_cast<KeyframeEffect*>(this)->applyEffects();
221 else if (m_sampledEffect) 223 else if (m_sampledEffect)
(...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after
371 373
372 DEFINE_TRACE(KeyframeEffect) 374 DEFINE_TRACE(KeyframeEffect)
373 { 375 {
374 visitor->trace(m_target); 376 visitor->trace(m_target);
375 visitor->trace(m_model); 377 visitor->trace(m_model);
376 visitor->trace(m_sampledEffect); 378 visitor->trace(m_sampledEffect);
377 AnimationEffect::trace(visitor); 379 AnimationEffect::trace(visitor);
378 } 380 }
379 381
380 } // namespace blink 382 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698