Sorry, I didn’t know what was Hermes. I’ve never used it, so I am not able to help.
Good luck.
Le 6 août 2014 à 10:39, Tom <HenryHa5@gmail.com> a écrit :
I did use ur code, but it didn't work as it still pick the default ID (id=1245)
On Wednesday, August 6, 2014 5:21:31 PM UTC+10, Fabien Dumay wrote:Hi Tom,Did you think to enable the i18n permutations?To to setup the german permutation, you have to add few lines in gwt module file (.gwt.xml):<inherits name="com.google.gwt.i18n.I18N"/> …<set-configuration-property name="locale.useragent" value="Y"/><set-configuration-property name="locale.searchorder" value="queryparam,cookie,meta,useragent"/> …<extend-property name="locale" values="en"/><extend-property name="locale" values="de"/><set-property-fallback name="locale" value="en"/>Hoping it helps.Regards,—FabienOk, I am building GWT app and I am using Hermes to manage the
constants
at Server side.Here is what I did:
I created
MyConstantsWithLookup.
(default English version) &properties MyConstantsWithLookup_de.
(German version) &properties MyConstantsWithLookup.java
in client package-MyConstantsWithLookup.
properties has id=1245
-MyConstantsWithLookup_de.
properties has id=4556
-MyConstantsWithLookup.javapublic interface MyConstantsWithLookup extends ConstantsWithLookup { int id(); }
There is
Data.java
in Server package.Data.java
haspublic static int id(){ try { MyConstantsWithLookup myConstantsWithLookup = Hermes.get(
MyConstantsWithLookup.class, ""); return myConstantsWithLookup.id(); } catch (IOException e) { // TODO Auto-generated catch block e.printStackTrace(); } return ""; } Ok, it works fine if i open the page in English. Ex,
myDomain.com
it will show correctly theid=1245
. However, if i open the page in German languagemyDomain.com?locale=de
then it did not pick up theid=4556
but still use the old id.Did i do anything wrong here?
How to fix it?
--
You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To post to this group, send email to google-we...@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit .
For more options, visit https://groups.google.com/d/optout .--
You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.
No comments:
Post a Comment