You should be able to use the same technique to determine the locale.
-= Mat
Another stratagem is to have the server return the locale as a URL
argument. Check out the I18N example for an example of that. The
I18N.gwt.xml property provider shows how to parse the URL arguments to
get the locale.
Finally, are you sure you need to access the locale in your program?
If you can use the built in GWT I18N support instead, the runtime
checks get pushed back into compile time optimizations, which leads to
smaller, faster code.
locale=en_US
Also, put this value in each of your other locale-sensitive-property
files. Then you can just use UserMessages.locale() method to get the
locale at runtime.
Nevertheless,
I agree that this small feature is necessary: getting the locale at
runtime.