Re: Loading please wait + Animated GIF

2010-04-14 Thread lineman78
I have noticed the same issue.  I know that javascript runs single
threaded, but I believe that the gif animation should run on a
seperate thread.  Have you run this experiment on browsers that use a
different threading model like the newer version of Chrome (soon
coming to FF).  Just because javascript is single threaded doesn't
mean that the rendering engine needs to be on that same thread.

On Apr 13, 4:30 am, Yogesh  wrote:
> Hi,
> I am showing a "Loading, please wait.." message along with an animated
> gif.
> For this I have added following in my host page.
>  Loading Please wait..
> I have usedhttp://www.ajaxload.info/ to generate a simple loading
> GIF image.
> And onModuleLoad() I am am removing this  before adding actual
> components into Rool Panel. This is working fine.
>
> The issue is that the animation of the GIF is not displayed. I found
> out that when javascript code in mymodule.nocache.js starts running in
> browser, the animation of GIF stops.
>
> I even wrote following HTML page to test this. When I click on Click
> me button, I just run some big for loop in javascript. When the
> javascript is running, the animation of GIF is stopped.
>
> 
> function bigJS()
> {
>         for (var i=1; i<=1000; i++);
>         alert('done');}
>
> 
> 
>  Loading Please wait..
>  onclick="bigJS()" />
> 
>
> Anyone know how to display the animated GIF properly?

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: Loading please wait + Animated GIF

2010-04-13 Thread Sripathi Krishnan
Javascript is single threaded, and I presume the entire page as well. If you
are running a javascript loop, the animation will appear sluggish or will
stop, there isn't much you can do about it.

If you want to run heavy javascript, use the IncrementalCommand or
DeferredCommand patterns. This would allow the browser to do other
activities, including animating the gif.

--Sri


On 13 April 2010 16:00, Yogesh  wrote:

> Hi,
> I am showing a "Loading, please wait.." message along with an animated
> gif.
> For this I have added following in my host page.
>  Loading Please wait..
> I have used http://www.ajaxload.info/  to generate a simple loading
> GIF image.
> And onModuleLoad() I am am removing this  before adding actual
> components into Rool Panel. This is working fine.
>
> The issue is that the animation of the GIF is not displayed. I found
> out that when javascript code in mymodule.nocache.js starts running in
> browser, the animation of GIF stops.
>
> I even wrote following HTML page to test this. When I click on Click
> me button, I just run some big for loop in javascript. When the
> javascript is running, the animation of GIF is stopped.
>
> 
> function bigJS()
> {
>for (var i=1; i<=1000; i++);
>alert('done');
> }
> 
> 
>  Loading Please wait..
>  onclick="bigJS()" />
> 
>
> Anyone know how to display the animated GIF properly?
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-tool...@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com
> .
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Loading please wait + Animated GIF

2010-04-13 Thread Yogesh
Hi,
I am showing a "Loading, please wait.." message along with an animated
gif.
For this I have added following in my host page.
 Loading Please wait..
I have used http://www.ajaxload.info/  to generate a simple loading
GIF image.
And onModuleLoad() I am am removing this  before adding actual
components into Rool Panel. This is working fine.

The issue is that the animation of the GIF is not displayed. I found
out that when javascript code in mymodule.nocache.js starts running in
browser, the animation of GIF stops.

I even wrote following HTML page to test this. When I click on Click
me button, I just run some big for loop in javascript. When the
javascript is running, the animation of GIF is stopped.


function bigJS()
{
for (var i=1; i<=1000; i++);
alert('done');
}


 Loading Please wait..



Anyone know how to display the animated GIF properly?

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.