Hello, my application has some standard icons like save, new, edit,
etc... but the user can customize the icons and specify the images he
wants the application to display at runtime. How can I accomplish this
using ClientBundle interface (the standard images would be specified
in the extended interface) and in runtime the system gets the custom
image instead of the standard one by loading from an URL?
I don't mind getting all the standard icons even if they won't be used
at all. Today my system loads all images by the URL, so the startup of
the application is too slow and most of the images are standard.
I would like to do something like this:
Image w = new Image(ResourceLoader.INSTANCE.background());
ResourceLoader looks if there is a customized image for background,
and if there is... loads from an URL, if not... calls the Resources
interface loading the standard one.
interface Resources extends ClientBundle {
Resources INSTANCE = GWT.create(Resources.class);
@Source("images/background.png")
ImageResource background();
}
Thanks!
Juan José Quito
--
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.