-
26 Apr 2012 4:23 PM #1
Unanswered: 'Loading' in GXT 3
Unanswered: 'Loading' in GXT 3
Hi,
With GXT 2, I had a 'loading' image (large-loading.gif) which was displayed in a <div> in the main index.html. Then, at the end of MainEntryPoint, I called:
GXT.hideLoadingPanel("loading");
Can anyone explain how to do the equivalent in GXT3 - there are no resources in the war directory any more.
Thanks,
Dan
-
26 Apr 2012 10:10 PM #2Ext GWT Premium Member
- Join Date
- Aug 2010
- Location
- Germany, Solingen
- Posts
- 223
- Vote Rating
- 2
- Answers
- 4
Hi,
this can be done with basis GWT features.
Just put a division with the ID 'loading' on your host page.
You can remove it with this code called in your EntryPoint:
FrankPHP Code:private void hideSplash() {
Timer delayedTimer = new Timer() {
@Override
public void run() {
Element splash = DOM.getElementById("loading");
if (splash != null && splash.hasParentElement()) {
splash.removeFromParent();
}
}
};
delayedTimer.schedule(1000);
}
-
27 Apr 2012 5:27 AM #3
Thanks, I'd just discovered this:
But I should have been clearer - the loading image that I'm using is:Code:DOM.removeChild(RootPanel.getBodyElement(), DOM.getElementById("loading"));
gxt/images/default/shared/large-loading.gif
Is there an equivalent in GXT 3? I believe that the resources have all been moved into embedded jar files.
-
27 Apr 2012 9:21 AM #4Ext GWT Premium Member
- Join Date
- Aug 2010
- Location
- Germany, Solingen
- Posts
- 223
- Vote Rating
- 2
- Answers
- 4
Well, why not using in with GXT 3?
Delete everything expect this image ...
-
27 Apr 2012 9:24 AM #5
Sure, that'll work. But I wanted to know the 'correct' way to do it with the new version. Is there no 'loading' resource provided in 3.0?
-
27 Apr 2012 9:25 AM #6Ext GWT Premium Member
- Join Date
- Aug 2010
- Location
- Germany, Solingen
- Posts
- 223
- Vote Rating
- 2
- Answers
- 4
I#ll think, this is the correct way.
If you use plain GWT you will do it in this way.
-
27 Apr 2012 9:33 AM #7
What if I didn't have a V2 'loading' gif - does V3 not provide a loading gif compiled into a jar? I believe that this is what it does with all the other resources (css, etc).
-
27 Apr 2012 9:35 AM #8Ext GWT Premium Member
- Join Date
- Aug 2010
- Location
- Germany, Solingen
- Posts
- 223
- Vote Rating
- 2
- Answers
- 4
Just take anything. Look for open source gifs. That's the way I solved it. ;-)


Reply With Quote