Hi, I am currently working on Ted's DatePicker component. It uses a Translator for parsing the entered String and convert it into a Date object. The Translator is registered like this:
| public static void contributeTranslatorSource(MappedConfiguration<String, | Translator> configuration) { | configuration.add("jsCalendarDateTranslator", new DateTranslator()); | } My problem is the date format is pretty locale-dependent. In Germany we would use something like dd.mm.yy or dd.mm.yyyy while in the English-speaking world we could have stuff like yyyy/mm/dd. Ideally I'd like the Translator to obtain the currently set locale (set using the ThreadLocale service in my main layout module which has a Language-dropdown) and use the date format which is most appropriate for it. However I found that any attempt to @Inject Locale, ThreadLocale or PersistentLocale always gave me null values. If I interpret the documentation well this should be expected anyway since a Translator is not a component (?), but what else can I do? Cheers, Martin -- ----------- / http://herbert.the-little-red-haired-girl.org / ------------- =+= In C you need #define to get real constants, like "#define FOO (rand())" --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]