HI All, I am using this code here: setTimeout("Sound.play(''sounds/movieprojector.mp3'');", 600); setTimeout("Effect.Appear(''slideshow5'');", 850 + 600); setTimeout("Effect.Puff(''slideshow5'');", 850 + 600 + 850); setTimeout("Effect.Appear(''slideshow6'');", 850 + 600 + 1700); How can I guarantee a consistent result each time? It seems that on IE PUFF makes the image move directly up while firefox makes it move diagonally upward to the left. In firefox it seems that the result is subtly different each time. Sometimes it is rough, sometimes it is smooth, and other times it seems that the effect is almost random. Thanks, -- Leonard Burton, N9URK http://www.jiffyslides.com service-CbOvBfcOUrWrJCssh9Shfg@public.gmane.org leonardburton-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org "The prolonged evacuation would have dramatically affected the survivability of the occupants." --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
You can''t rely on setTimeout. Scriptaculous provides a queue functionality [1] for things like that: function sequence() { var options = { queue: ''end'' }; $(''slideshow5'').appear(options); $(''slideshow5'').puff(options); $(''slideshow6'').appear(options); } // call sequence in 0.6 seconds sequence.delay(0.6); or using anonymous function: (function(){ var options = { queue: ''end'' }; $(''slideshow5'').appear(options); $(''slideshow5'').puff(options); $(''slideshow6'').appear(options); }).delay(0.6) [1] http://wiki.script.aculo.us/scriptaculous/show/EffectQueues - kangax On Apr 27, 12:51 pm, "Leonard Burton" <leonardbur...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> HI All, > > I am using this code here: > > setTimeout("Sound.play(''sounds/movieprojector.mp3'');", 600); > setTimeout("Effect.Appear(''slideshow5'');", 850 + 600); > setTimeout("Effect.Puff(''slideshow5'');", 850 + 600 + 850); > setTimeout("Effect.Appear(''slideshow6'');", 850 + 600 + 1700); > > How can I guarantee a consistent result each time? > > It seems that on IE PUFF makes the image move directly up while > firefox makes it move diagonally upward to the left. > > In firefox it seems that the result is subtly different each time. > > Sometimes it is rough, sometimes it is smooth, and other times it > seems that the effect is almost random. > > Thanks, > > -- > Leonard Burton, N9URKhttp://www.jiffyslides.com > serv...-CbOvBfcOUrWrJCssh9Shfg@public.gmane.org > leonardbur...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org > > "The prolonged evacuation would have dramatically affected the > survivability of the occupants."--~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Leonard Burton
2008-Apr-27 18:04 UTC
Re: Smoothing out effects/ consistent effects everytime
HI, Thanks for the reply,> You can''t rely on setTimeout. Scriptaculous provides a queue > functionality [1] for things like that:How are sound effects added to the queue? -- Leonard Burton, N9URK http://www.jiffyslides.com service-CbOvBfcOUrWrJCssh9Shfg@public.gmane.org leonardburton-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org "The prolonged evacuation would have dramatically affected the survivability of the occupants." --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Leonard Burton
2008-Apr-27 18:26 UTC
Re: Smoothing out effects/ consistent effects everytime
HI,> > You can''t rely on setTimeout. Scriptaculous provides a queue > > functionality [1] for things like that: > How are sound effects added to the queue?I got it. I didn''t think it was playing the effects when indeed it was. I had my mute turned on on the laptop :) Thanks, it seems to be working now. -- Leonard Burton, N9URK http://www.jiffyslides.com service-CbOvBfcOUrWrJCssh9Shfg@public.gmane.org leonardburton-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org "The prolonged evacuation would have dramatically affected the survivability of the occupants." --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
I don''t think Sound.play provides callbacks or queuing (I''m guessing due to a browser limitations) - kangax On Apr 27, 2:26 pm, "Leonard Burton" <leonardbur...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> HI, > > > > You can''t rely on setTimeout. Scriptaculous provides a queue > > > functionality [1] for things like that: > > How are sound effects added to the queue? > > I got it. I didn''t think it was playing the effects when indeed it > was. I had my mute turned on on the laptop :) > > Thanks, it seems to be working now. > > -- > Leonard Burton, N9URKhttp://www.jiffyslides.com > serv...-CbOvBfcOUrWrJCssh9Shfg@public.gmane.org > leonardbur...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org > > "The prolonged evacuation would have dramatically affected the > survivability of the occupants."--~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---