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

Unified Diff: Source/core/svg/animation/SVGSMILElement.cpp

Issue 22385010: [SVG] Handle endEvent for svg animations (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 7 years, 4 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/animation/SVGSMILElement.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/svg/animation/SVGSMILElement.cpp
diff --git a/Source/core/svg/animation/SVGSMILElement.cpp b/Source/core/svg/animation/SVGSMILElement.cpp
index c229f9544fca5d9521fe688681fd058adececdc4..c5e364cf5458209df2ff9295d92eedee806469a4 100644
--- a/Source/core/svg/animation/SVGSMILElement.cpp
+++ b/Source/core/svg/animation/SVGSMILElement.cpp
@@ -1051,9 +1051,6 @@ bool SVGSMILElement::progress(SMILTime elapsed, SVGSMILElement* resultElement, b
ASSERT(m_timeContainer);
ASSERT(m_isWaitingForFirstInterval || m_intervalBegin.isFinite());
- if (!m_conditionsConnected)
- connectConditions();
-
if (!m_intervalBegin.isFinite()) {
ASSERT(m_activeState == Inactive);
m_nextProgressTime = SMILTime::unresolved();
@@ -1110,11 +1107,18 @@ bool SVGSMILElement::progress(SMILTime elapsed, SVGSMILElement* resultElement, b
}
if (oldActiveState == Active && m_activeState != Active) {
+ dispatchEvent(Event::create("endEvent", false, false));
pdr. 2013/08/29 21:15:06 Unfortunately, synchronously calling dispatchEvent
endedActiveInterval();
if (m_activeState != Frozen && this == resultElement)
clearAnimatedType(m_targetElement);
}
+ // Triggering all the pending events if the animation timeline is changed.
+ if (seekToTime) {
+ if (m_activeState == Inactive || m_activeState == Frozen)
+ dispatchEvent(Event::create("endEvent", false, false));
pdr. 2013/08/29 21:15:06 ditto here
+ }
+
m_nextProgressTime = calculateNextProgressTime(elapsed);
return animationIsContributing;
}
« no previous file with comments | « Source/core/svg/animation/SVGSMILElement.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698