vcl/source/app/svmain.cxx | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-)
New commits: commit 8f629b8fbeb13a593f6aff28d2ff0399eb4ee56a Author: Caolán McNamara <caol...@redhat.com> Date: Sat Aug 5 16:44:39 2017 +0100 set LANGUAGE from SvtSysLocale().GetUILanguageTag() Change-Id: I466576660bdc281c3332fa25f0fe0756cd356ab7 Reviewed-on: https://gerrit.libreoffice.org/40788 Tested-by: Jenkins <c...@libreoffice.org> Reviewed-by: Caolán McNamara <caol...@redhat.com> Tested-by: Caolán McNamara <caol...@redhat.com> diff --git a/vcl/source/app/svmain.cxx b/vcl/source/app/svmain.cxx index 61f589aaf93a..1b88fc290157 100644 --- a/vcl/source/app/svmain.cxx +++ b/vcl/source/app/svmain.cxx @@ -322,18 +322,15 @@ bool InitVCL() pSVData->mpApp->Init(); } - if (pSVData->maAppData.mpSettings) - { - //Now that uno has been bootstrapped we can ask the config what the UI language is so that we can - //force that in as $LANGUAGE. That way we can get gtk to render widgets RTL - //if we have a RTL UI in an otherwise LTR locale and get gettext using externals (e.g. python) - //to match their translations to our preferred UI language - OUString aLocaleString(pSVData->maAppData.mpSettings->GetUILanguageTag().getGlibcLocaleString(".UTF-8")); - if (!aLocaleString.isEmpty()) - { - OUString envVar("LANGUAGE"); - osl_setEnvironment(envVar.pData, aLocaleString.pData); - } + //Now that uno has been bootstrapped we can ask the config what the UI language is so that we can + //force that in as $LANGUAGE. That way we can get gtk to render widgets RTL + //if we have a RTL UI in an otherwise LTR locale and get gettext using externals (e.g. python) + //to match their translations to our preferred UI language + OUString aLocaleString(SvtSysLocaleOptions().GetRealUILanguageTag().getGlibcLocaleString(".UTF-8")); + if (!aLocaleString.isEmpty()) + { + OUString envVar("LANGUAGE"); + osl_setEnvironment(envVar.pData, aLocaleString.pData); } pSVData->mpDefInst->AfterAppInit();
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits