01: package org.tp23.antinstaller.input;
02:
03: import java.util.Locale;
04:
05: import org.tp23.antinstaller.InstallerContext;
06:
07: public class LangSelectInput extends LargeSelectInput {
08:
09: public void setInputResult(String locale) {
10: super .setInputResult(locale);
11: String[] parts = locale.split("_");
12: if (parts.length == 1) {
13: Locale.setDefault(new Locale(parts[0]));
14: }
15: if (parts.length == 2) {
16: Locale.setDefault(new Locale(parts[0], parts[1]));
17: }
18: if (parts.length == 3) {
19: Locale.setDefault(new Locale(parts[0], parts[1], parts[2]));
20: }
21: InstallerContext.reInitLocale();
22: }
23:
24: }
|