Added method to get the Locale object that the client is using.
This may be different from the default Locale. git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@3746 542714f4-19e9-0310-aa3c-eee0fc999fb1
This commit is contained in:
@@ -81,6 +81,17 @@ public class MessageManager
|
||||
_global = getBundle(GLOBAL_BUNDLE);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the locale that is being used to translate messages.
|
||||
* This may be useful if using standard translations, for example
|
||||
* new SimpleDateFormat("EEEE", getLocale()) to get the name of a weekday
|
||||
* that matches the language being used for all other client translations.
|
||||
*/
|
||||
public Locale getLocale ()
|
||||
{
|
||||
return _locale;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the locale to the specified locale. Subsequent message bundles
|
||||
* fetched via the message manager will use the new locale. The
|
||||
|
||||
Reference in New Issue
Block a user