Revert "core: use set_lang_locale to modify prefs.locale.lang_locale"

This reverts commit 573a4a5e2d.

The commit broke setting the language in the desktop preferences:
Instead of setting the locale in the prefs struct, the locale
is set via qPrefLanguage. However, that saves the default language
(extracted from the system) to disk. Now when the language is
read from the preferences, we get that default value.

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
Berthold Stoeger 2020-03-21 23:01:49 +01:00 committed by Dirk Hohndel
parent f9b8d16a0d
commit 2db7d5cc23

View file

@ -471,7 +471,7 @@ QString uiLanguage(QLocale *callerLoc)
else
uiLang = languages[0];
qPrefLanguage::set_lang_locale(uiLang);
prefs.locale.lang_locale = copy_qstring(uiLang);
// there's a stupid Qt bug on MacOS where uiLanguages doesn't give us the country info
if (!uiLang.contains('-') && uiLang != loc.bcp47Name()) {