Turkish locale toLowerCase I problem fix (causing not loading main window because of icon names conversion, etc.)

This commit is contained in:
Jindra Petřík
2018-04-01 16:26:32 +02:00
parent 5717035254
commit c2f729b3bf
14 changed files with 69 additions and 57 deletions

View File

@@ -54,6 +54,7 @@ import java.awt.FlowLayout;
import java.awt.event.ActionEvent;
import java.util.Arrays;
import java.util.List;
import java.util.Locale;
import javax.swing.JButton;
import javax.swing.JCheckBox;
import javax.swing.JComboBox;
@@ -168,7 +169,7 @@ public class ExportDialog extends AppDialog {
int selIndex = combos[i].getSelectedIndex();
Class c = optionClasses[i];
Object[] vals = c.getEnumConstants();
String key = optionNames[i] + "." + vals[selIndex].toString().toLowerCase();
String key = optionNames[i] + "." + vals[selIndex].toString().toLowerCase(Locale.ENGLISH);
if (i > 0) {
cfg.append(",");
}
@@ -276,7 +277,7 @@ public class ExportDialog extends AppDialog {
int itemIndex = -1;
for (int j = 0; j < vals.length; j++) {
String key = optionNames[i] + "." + vals[j].toString().toLowerCase();
String key = optionNames[i] + "." + vals[j].toString().toLowerCase(Locale.ENGLISH);
if (exportFormats.contains(key)) {
itemIndex = j;
}