[Libreoffice-commits] core.git: include/unotools unotools/source
Noel Grandin (via logerrit)
logerrit at kemper.freedesktop.org
Thu Jul 29 15:38:33 UTC 2021
include/unotools/localedatawrapper.hxx | 6 +++---
unotools/source/i18n/localedatawrapper.cxx | 6 +++---
2 files changed, 6 insertions(+), 6 deletions(-)
New commits:
commit 27457150b1c85cbf7c084b0930a71b0106b8278b
Author: Noel Grandin <noel.grandin at collabora.co.uk>
AuthorDate: Thu Jul 29 14:47:39 2021 +0200
Commit: Noel Grandin <noel.grandin at collabora.co.uk>
CommitDate: Thu Jul 29 17:37:58 2021 +0200
return by const& in LocaleDataWrapper
Change-Id: Id5075424867ae1017df9fa0cd2df802d529e32d5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119666
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>
diff --git a/include/unotools/localedatawrapper.hxx b/include/unotools/localedatawrapper.hxx
index 0a0832b64a13..94cc9be3425a 100644
--- a/include/unotools/localedatawrapper.hxx
+++ b/include/unotools/localedatawrapper.hxx
@@ -157,12 +157,12 @@ public:
css::uno::Sequence< css::i18n::Currency2 > getAllCurrencies() const;
css::uno::Sequence< css::i18n::FormatElement > getAllFormats() const;
css::i18n::ForbiddenCharacters getForbiddenCharacters() const;
- css::uno::Sequence< css::lang::Locale > getAllInstalledLocaleNames() const;
+ const css::uno::Sequence< css::lang::Locale > & getAllInstalledLocaleNames() const;
css::uno::Sequence< OUString > getDateAcceptancePatterns() const;
/// same as the wrapper implementation but static
- static css::uno::Sequence< css::lang::Locale > getInstalledLocaleNames();
+ static const css::uno::Sequence< css::lang::Locale > & getInstalledLocaleNames();
/** Get LanguageTypes for all installed locales which are unambiguous
convertible back and forth between locale ISO strings and MS-LCID
@@ -171,7 +171,7 @@ public:
matching, excluding already known problems.
(e.g. used in number formatter dialog init)
*/
- static std::vector< LanguageType > getInstalledLanguageTypes();
+ static const std::vector< LanguageType > & getInstalledLanguageTypes();
/// maps the LocaleData string to the International enum
MeasurementSystem mapMeasurementStringToEnum( const OUString& rMS ) const;
diff --git a/unotools/source/i18n/localedatawrapper.cxx b/unotools/source/i18n/localedatawrapper.cxx
index b6a286a07fc2..1793b8594eeb 100644
--- a/unotools/source/i18n/localedatawrapper.cxx
+++ b/unotools/source/i18n/localedatawrapper.cxx
@@ -269,7 +269,7 @@ css::i18n::ForbiddenCharacters LocaleDataWrapper::getForbiddenCharacters() const
return css::i18n::ForbiddenCharacters();
}
-css::uno::Sequence< css::lang::Locale > LocaleDataWrapper::getAllInstalledLocaleNames() const
+const css::uno::Sequence< css::lang::Locale > & LocaleDataWrapper::getAllInstalledLocaleNames() const
{
uno::Sequence< lang::Locale > &rInstalledLocales = gInstalledLocales;
@@ -290,7 +290,7 @@ css::uno::Sequence< css::lang::Locale > LocaleDataWrapper::getAllInstalledLocale
// --- Impl and helpers ----------------------------------------------------
// static
-css::uno::Sequence< css::lang::Locale > LocaleDataWrapper::getInstalledLocaleNames()
+const css::uno::Sequence< css::lang::Locale >& LocaleDataWrapper::getInstalledLocaleNames()
{
const uno::Sequence< lang::Locale > &rInstalledLocales = gInstalledLocales;
@@ -303,7 +303,7 @@ css::uno::Sequence< css::lang::Locale > LocaleDataWrapper::getInstalledLocaleNam
}
// static
-std::vector< LanguageType > LocaleDataWrapper::getInstalledLanguageTypes()
+const std::vector< LanguageType >& LocaleDataWrapper::getInstalledLanguageTypes()
{
std::vector< LanguageType > &rInstalledLanguageTypes = gInstalledLanguageTypes;
More information about the Libreoffice-commits
mailing list