mirror of
https://github.com/ViaVersion/ViaProxy.git
synced 2024-12-02 12:17:28 -05:00
Don't trigger language change when the language isn't actually changed
This commit is contained in:
parent
1c18ce4699
commit
75c0434ceb
1 changed files with 1 additions and 0 deletions
|
@ -62,6 +62,7 @@ public class UISettingsTab extends AUITab {
|
||||||
language.setSelectedItem(I18n.getCurrentLocale());
|
language.setSelectedItem(I18n.getCurrentLocale());
|
||||||
language.addActionListener(event -> {
|
language.addActionListener(event -> {
|
||||||
if (!(language.getSelectedItem() instanceof String locale)) return;
|
if (!(language.getSelectedItem() instanceof String locale)) return;
|
||||||
|
if (locale.equals(I18n.getCurrentLocale())) return;
|
||||||
I18n.setLocale(locale);
|
I18n.setLocale(locale);
|
||||||
ViaProxy.ui.showInfo(I18n.get("tab.ui_settings.language.success", I18n.get("language.name"), locale));
|
ViaProxy.ui.showInfo(I18n.get("tab.ui_settings.language.success", I18n.get("language.name"), locale));
|
||||||
try {
|
try {
|
||||||
|
|
Loading…
Reference in a new issue