Is there some way to easily internationalize images (using g:Image and ImageResource) in GWT?
From what I can see, it is possible to internationalize the src attribute of a img element, using:
<img src="http://www.images.com/englishVersionOfImage.png" alt="">
<ui:attribute name="src" description="Image to be internationalized"/>
</img>
and by changing the src value in the appropriate LocalizableResource_xxxx.properties file.
However, this technique does not seem to be applicable to
<g:Image resource="{resources.MyImageResource}"/> elements.
Should be as simple as with all other source types (https://developers.google.com/web-toolkit/doc/latest/DevGuideClientBundle#I18N).
In simple words, if you use something like this for text labels:
, then try the same technique with images:
The proper file should have been chosen depending on current locale.
So, considering the example from https://developers.google.com/web-toolkit/doc/latest/DevGuideUiBinder#Using_an_external_resource use:
and then have a class