Hi, Mariyan!
you have just to set window.onload handler in your module's entry
point, ie:
(we aware that i have not tried to compile it, and i am not sure if it
will trigger if installed after the window is actually load, which
could happen for instance when the images are in the browser cache)
public class MyEntryPoint implements EntryPoint {
public void onModuleLoad() {
Label loadingLabel = new Label("Loading...");
RootPanel.get().add(loadingLabel);
setLoadHandler();
}
public native void setLoadHandler() /*-{
var oldOnload = $wnd.onload;
$wnd.onload = function() {
[email protected]::onWindowLoad()();
$wnd.onload = oldOnload;
$wnd.onload();
}
}-*/;
public void onWindowLoad() {
RootPanel.get().clear();
// start with your stuff here
...
}
}
HTH
Michael
ps: i had to use JSNI because i could not find any way to set a
LoadHandler on the (com.google.gwt.user.client.)Window object...
--
You received this message because you are subscribed to the Google Groups
"Google Web Toolkit" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/google-web-toolkit?hl=en.