raul.andres-Dk5a5gKDBemh6J55Ss3d3w@public.gmane.org
2006-May-26 22:40 UTC
stopping effects, help me again please
Hi * and thanks for you responses
some body help me stop effect, just last effect.
Thanks! to somebody help me with:
Pulsator = Class.create();
Pulsator.prototype = {initialize: function(element)
{
this.stopped = false;
new Effect.Pulsate(element, { afterFinish: this.action.bind(this) });
},action: function(element){if(!this.stopped) new Effect.Pulsate(element,
{ afterFinish: this.action.bind(this) });
},stop: function(element) {this.stopped = true;}
}
but this solution doesn''t work to stop.
thanks in advance
rag
raul.andres-Dk5a5gKDBemh6J55Ss3d3w@public.gmane.org
2006-May-28 12:31 UTC
stopping effects, help me again please
Hi * and thanks for you responses
some body help me stop effect, just last effect.
Thanks! to somebody help me with:
Pulsator = Class.create();
Pulsator.prototype = {initialize: function(element)
{
this.stopped = false;
new Effect.Pulsate(element, { afterFinish:
this.action.bind(this) });
},action: function(element){if(!this.stopped) new
Effect.Pulsate(element,
{ afterFinish: this.action.bind(this) });
},stop: function(element) {this.stopped = true;}
}
but this solution work to stop but it lost duration feature
thanks in advance
rag
hi rag,
it''s easy to pass the options (duration etc) through to you effect
call:
Pulsator = Class.create();
Pulsator.prototype = {initialize: function(element,options)
{
this.options = options || {};
this.options.afterFinish = this.action.bind(this);
this.stopped = false;
new Effect.Pulsate(element, this.options);
},
action: function(element){
if(!this.stopped) new Effect.Pulsate(element,this.options);
},
stop: function(element) {
this.stopped = true;
}
}
simple call:
var pulsator = new Pulsator(myelement, { duration: 0.3 });
hth
Sigi
On 5/28/06, raul.andres-Dk5a5gKDBemh6J55Ss3d3w@public.gmane.org
<raul.andres-Dk5a5gKDBemh6J55Ss3d3w@public.gmane.org>
wrote:>
> Hi * and thanks for you responses
>
> some body help me stop effect, just last effect.
>
> Thanks! to somebody help me with:
>
> Pulsator = Class.create();
> Pulsator.prototype = {initialize: function(element)
> {
> this.stopped = false;
> new Effect.Pulsate(element, { afterFinish:
> this.action.bind(this) });
> },action: function(element){if(!this.stopped) new
> Effect.Pulsate(element,
> { afterFinish: this.action.bind(this) });
> },stop: function(element) {this.stopped = true;}
> }
> but this solution work to stop but it lost duration feature
>
> thanks in advance
> rag
>
> _______________________________________________
> Rails-spinoffs mailing list
> Rails-spinoffs-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org
> http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs
>
--
Mit freundlichen Grüßen
Siegfried Puchbauer
_______________________________________________
Rails-spinoffs mailing list
Rails-spinoffs-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org
http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs
Uh... I saw there was still a mistake... this should work:
Pulsator = Class.create();
Pulsator.prototype = {initialize: function(element,options)
{
this.element = element;
this.options = options || {};
this.options.afterFinish = this.action.bind(this);
this.stopped = false;
this.action();
},
action: function(){
if(!this.stopped) new Effect.Pulsate (this.element,this.options);
},
stop: function() {
this.stopped = true;
}
}
brgds
Sigi
On 5/29/06, Siegfried Puchbauer
<siegfried.puchbauer-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
wrote:>
> hi rag,
>
> it''s easy to pass the options (duration etc) through to you effect
call:
>
> Pulsator = Class.create();
> Pulsator.prototype = {initialize: function(element,options)
> {
> this.options = options || {};
> this.options.afterFinish = this.action.bind(this);
> this.stopped = false;
> new Effect.Pulsate(element, this.options);
> },
> action: function(element){
> if(!this.stopped) new Effect.Pulsate (element,this.options);
> },
>
> stop: function(element) {
> this.stopped = true;
> }
> }
>
> simple call:
> var pulsator = new Pulsator(myelement, { duration: 0.3 });
>
> hth
>
> Sigi
>
>
> On 5/28/06, raul.andres-Dk5a5gKDBemh6J55Ss3d3w@public.gmane.org
<raul.andres-Dk5a5gKDBemh6J55Ss3d3w@public.gmane.org> wrote:
> >
> > Hi * and thanks for you responses
> >
> > some body help me stop effect, just last effect.
> >
> > Thanks! to somebody help me with:
> >
> > Pulsator = Class.create();
> > Pulsator.prototype = {initialize: function(element)
> > {
> > this.stopped = false;
> > new Effect.Pulsate(element, { afterFinish:
> > this.action.bind(this) });
> > },action: function(element){if(!this.stopped) new
> > Effect.Pulsate (element,
> > { afterFinish: this.action.bind(this) });
> > },stop: function(element) {this.stopped = true;}
> > }
> > but this solution work to stop but it lost duration feature
> >
> > thanks in advance
> > rag
> >
> > _______________________________________________
> > Rails-spinoffs mailing list
> > Rails-spinoffs-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org
> > http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs
> >
>
>
>
> --
> Mit freundlichen Grüßen
>
> Siegfried Puchbauer
>
--
Mit freundlichen Grüßen
Siegfried Puchbauer
_______________________________________________
Rails-spinoffs mailing list
Rails-spinoffs-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org
http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs
raul.andres-Dk5a5gKDBemh6J55Ss3d3w@public.gmane.org
2006-May-30 16:11 UTC
Re: stopping effects, help me again please
ei Sigi on first thanks problem real and original is line: this.stopped = true; doesn''t work, are you sure? Where is my error? do you know? i test to Hide effect and then a Appear effect but not work :( thanks rag> Uh... I saw there was still a mistake... this should work: > > Pulsator = Class.create(); > Pulsator.prototype = {initialize: function(element,options) > { > this.element = element; > this.options = options || {}; > this.options.afterFinish = this.action.bind(this); > this.stopped = false; > this.action(); > }, > action: function(){ > if(!this.stopped) new Effect.Pulsate (this.element,this.options); > }, > > stop: function() { > this.stopped = true; > } > } > > brgds > > Sigi > > On 5/29/06, Siegfried Puchbauer <siegfried.puchbauer-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: >> >> hi rag, >> >> it''s easy to pass the options (duration etc) through to you effect call: >> >> Pulsator = Class.create(); >> Pulsator.prototype = {initialize: function(element,options) >> { >> this.options = options || {}; >> this.options.afterFinish = this.action.bind(this); >> this.stopped = false; >> new Effect.Pulsate(element, this.options); >> }, >> action: function(element){ >> if(!this.stopped) new Effect.Pulsate (element,this.options); >> }, >> >> stop: function(element) { >> this.stopped = true; >> } >> } >> >> simple call: >> var pulsator = new Pulsator(myelement, { duration: 0.3 }); >> >> hth >> >> Sigi >> >> >> On 5/28/06, raul.andres-Dk5a5gKDBemh6J55Ss3d3w@public.gmane.org <raul.andres-Dk5a5gKDBemh6J55Ss3d3w@public.gmane.org> wrote: >> > >> > Hi * and thanks for you responses >> > >> > some body help me stop effect, just last effect. >> > >> > Thanks! to somebody help me with: >> > >> > Pulsator = Class.create(); >> > Pulsator.prototype = {initialize: function(element) >> > { >> > this.stopped = false; >> > new Effect.Pulsate(element, { afterFinish: >> > this.action.bind(this) }); >> > },action: function(element){if(!this.stopped) new >> > Effect.Pulsate (element, >> > { afterFinish: this.action.bind(this) }); >> > },stop: function(element) {this.stopped = true;} >> > } >> > but this solution work to stop but it lost duration feature >> > >> > thanks in advance >> > rag >> > >> > _______________________________________________ >> > Rails-spinoffs mailing list >> > Rails-spinoffs-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org >> > http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs >> > >> >> >> >> -- >> Mit freundlichen Grüßen >> >> Siegfried Puchbauer >> > > > > -- > Mit freundlichen Grüßen > > Siegfried Puchbauer > _______________________________________________ > Rails-spinoffs mailing list > Rails-spinoffs-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs >Un saludo. Raúl Andrés Dir. Gerente La tecnología es útil. Util es McTux:// www.mctux.com CL CAMINO VALDERRIBAS, 34 E-28038 Madrid Tlf/Fax: (+34) 91 501 10 90 In a free world, Who needs windows or gates?