On 5 juin 2006, at 19:50, Augusto Erzinger Jr. wrote:

> Is there anyone who knows how I could stop an SVG animateColor  
> animation
> by a way other than direct user interaction like mousedown or click or
> focusin? I intend to stop the animation from within a javascript
> function. I thougth that I could get it by setting the DOMAttrModified
> to the 'end' event attribute of my animated widget, adding an event
> listener with parameter DOMAttrModified to it, then (at a specific
> moment) setting the 'fill' attribute of the widget (via setAttribute
> method). Well... this procedure didn't work.

Make sure that your <animateColor> has an "end" attribute with value  
"undefined", which allows you to call the endElement() method on the  
DOM object representing that element.

SVG:

<animateColor id="my_anim" ... end="indefinite" />

JS:

// get a pointer to the animation element
var anim = document.getElementById('my_anim');
// stops the animation
anim.endElement();

Antoine
-- 
Antoine Quint — Fuchsia Design
SVG & Client-side XML Consulting
W3C SVG WG Invited Expert
http://fuchsia-design.com




[Non-text portions of this message have been removed]



------------------------ Yahoo! Groups Sponsor --------------------~--> 
Everything you need is one click away.  Make Yahoo! your home page now.
http://us.click.yahoo.com/AHchtC/4FxNAA/yQLSAA/1U_rlB/TM
--------------------------------------------------------------------~-> 

-----
To unsubscribe send a message to: [EMAIL PROTECTED]
-or-
visit http://groups.yahoo.com/group/svg-developers and click "edit my 
membership"
---- 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/svg-developers/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to