jQuery busy.gif

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

jQuery busy.gif

Paul DeBruicker
Hi -

I'd like to display a busy indicator like Lukas Renggli describes here:

http://lists.squeakfoundation.org/pipermail/seaside/2006-August/008862.html

But so far I've only used jQuery and not Prototype or Scriptaculous in
my project and don't know if it is reasonable to add them just to get
a busy indicator.

 Is there a way to display a busy indicator and then have it exit when
a full page refresh is complete using just jQuery?

 If I should use both Prototype and jQuery, does it matter how I load
them into the application?

Thanks

Paul
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: jQuery busy.gif

Philippe Marschall
2009/9/1 Paul DeBruicker <[hidden email]>:

> Hi -
>
> I'd like to display a busy indicator like Lukas Renggli describes here:
>
> http://lists.squeakfoundation.org/pipermail/seaside/2006-August/008862.html
>
> But so far I've only used jQuery and not Prototype or Scriptaculous in
> my project and don't know if it is reasonable to add them just to get
> a busy indicator.
>
>  Is there a way to display a busy indicator and then have it exit when
> a full page refresh is complete using just jQuery?

Can you try to replace the #onClick: values with only this one:

(html jQuery id: 'spinner'; show),
(html javascript return: true)


Cheers
Philippe
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: jQuery busy.gif

Lukas Renggli
In reply to this post by Paul DeBruicker
> But so far I've only used jQuery and not Prototype or Scriptaculous in
> my project and don't know if it is reasonable to add them just to get
> a busy indicator.

I wouldn't mix them if you don't have strong (legacy) reasons to do so.

>  Is there a way to display a busy indicator and then have it exit when
> a full page refresh is complete using just jQuery?

Sure, do it the same as described in this mail, but instead use

     (html jQuery: #spinner) show

to fade in the spinner. Similarly you can setup to show the spinner
globally for all AJAX actions by adding the following expression to
the bottom of your page:

    html script: (html jQuery ajaxSetup
        onBeforeSend: (html jQuery: #spinner) show;
        onComplete: (html jQuery: #spinner) hide)

Search Google and the jQuery documentation for more samples.

Lukas

--
Lukas Renggli
http://www.lukas-renggli.ch
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside