Hey there,
Jean-Christophe Roux a écrit :> I have this Effect.Fade on an image running for a duration of 4 seconds.
> I''d like my user to be able to stop the fading and resume it. I
don''t
> know how to stop the effect, keep the image as it is and resume the
> fading on a button click. What would be the functions to stop and resume
> and Effect?
The current effect engine is not designed to let this happen easily:
it''s heavily based on the scheduled time of termination to work, and
this scheduling happens only when you start the effect. There are no
pause/resume facilities at this time.
It can be coded, but it''s not very straightforward: it''s
downright hackish.
If it is any consolation, script.aculo.us 2.0 will feature a
100%-rewritten effect engine which should, among many other benefits,
make pausing/resuming much easier :-) However, it''s not releasing
anytime soon :-/
--
Christophe Porteneuve aka TDD
tdd-x+CfDp/qHev2eFz/2MeuCQ@public.gmane.org
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Spinoffs" group.
To post to this group, send email to
rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-spinoffs?hl=en
-~----------~----~----~----~------~----~------~--~---