[Libreoffice-commits] core.git: Branch 'libreoffice-4-2' - comphelper/source configmgr/source desktop/source
Eike Rathke
erack at redhat.com
Sun Jan 19 06:24:25 PST 2014
comphelper/source/misc/configuration.cxx | 2 +-
configmgr/source/configurationprovider.cxx | 2 +-
desktop/source/app/langselect.cxx | 3 +++
3 files changed, 5 insertions(+), 2 deletions(-)
New commits:
commit cf32bd06da9d215e8a337ad611651664142e8a65
Author: Eike Rathke <erack at redhat.com>
Date: Fri Jan 17 19:21:56 2014 +0100
fdo#73549 do not attempt to resolve an empty locale
... to match installed UI locales
Change-Id: If0ad0fde392bc5ea3cf454f4858330f5e93a6666
(cherry picked from commit 8e826c7ff7c597e9f585377b2117f4dc24239dcc)
fdo#73549 do not resolve empty locale here if not determined yet
Change-Id: Iad03d6209a2b4024b27c6195195e5aa557c295fe
(cherry picked from commit db6f8f9f8969b592ed90c841960fdd186e1cbc5a)
do not resolve empty locale here when set, fdo#73549 related
Change-Id: Id9c8c3926f64826fd2295e0f75f007ce435f5915
(cherry picked from commit 26fc9be1bf2d6aaeb52a571ea416f4527a52e146)
Reviewed-on: https://gerrit.libreoffice.org/7529
Reviewed-by: Andras Timar <andras.timar at collabora.com>
Tested-by: Andras Timar <andras.timar at collabora.com>
diff --git a/comphelper/source/misc/configuration.cxx b/comphelper/source/misc/configuration.cxx
index 69885b9..6f9e5fd 100644
--- a/comphelper/source/misc/configuration.cxx
+++ b/comphelper/source/misc/configuration.cxx
@@ -47,7 +47,7 @@ OUString getDefaultLocale(
css::uno::Reference< css::lang::XLocalizable >(
css::configuration::theDefaultProvider::get(context),
css::uno::UNO_QUERY_THROW)->
- getLocale()).getBcp47();
+ getLocale()).getBcp47(false);
}
OUString extendLocalizedPath(OUString const & path, OUString const & locale) {
diff --git a/configmgr/source/configurationprovider.cxx b/configmgr/source/configurationprovider.cxx
index a4aaa15..7293e9f 100644
--- a/configmgr/source/configurationprovider.cxx
+++ b/configmgr/source/configurationprovider.cxx
@@ -324,7 +324,7 @@ void Service::setLocale(css::lang::Locale const & eLocale)
throw (css::uno::RuntimeException)
{
osl::MutexGuard guard(*lock_);
- locale_ = LanguageTag::convertToBcp47( eLocale);
+ locale_ = LanguageTag::convertToBcp47( eLocale, false);
}
css::lang::Locale Service::getLocale() throw (css::uno::RuntimeException) {
diff --git a/desktop/source/app/langselect.cxx b/desktop/source/app/langselect.cxx
index 291e708..21228f8 100644
--- a/desktop/source/app/langselect.cxx
+++ b/desktop/source/app/langselect.cxx
@@ -53,6 +53,9 @@ OUString foundLocale;
OUString getInstalledLocale(
css::uno::Sequence<OUString> const & installed, OUString const & locale)
{
+ if (locale.isEmpty())
+ return OUString(); // do not attempt to resolve anything
+
for (sal_Int32 i = 0; i != installed.getLength(); ++i) {
if (installed[i] == locale) {
return installed[i];
More information about the Libreoffice-commits
mailing list