[Libreoffice-commits] core.git: cui/source
Caolán McNamara (via logerrit)
logerrit at kemper.freedesktop.org
Thu Sep 19 10:41:50 UTC 2019
cui/source/options/optgdlg.cxx | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
New commits:
commit a9e0ca2a5f816d4d8a4cd5f079aee0fc2aab0b7a
Author: Caolán McNamara <caolanm at redhat.com>
AuthorDate: Thu Sep 19 10:25:31 2019 +0100
Commit: Caolán McNamara <caolanm at redhat.com>
CommitDate: Thu Sep 19 12:41:03 2019 +0200
use an explicit id for the default currency
Change-Id: I437966b55226805d6de83b17221318eb1f0279b8
Reviewed-on: https://gerrit.libreoffice.org/79116
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
Tested-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/cui/source/options/optgdlg.cxx b/cui/source/options/optgdlg.cxx
index 2ef0e6fa8b78..1d95f8ab8720 100644
--- a/cui/source/options/optgdlg.cxx
+++ b/cui/source/options/optgdlg.cxx
@@ -1192,7 +1192,8 @@ OfaLanguagesTabPage::OfaLanguagesTabPage(TabPageParent pParent, const SfxItemSet
const NfCurrencyEntry& rCurr = SvNumberFormatter::GetCurrencyEntry( LANGUAGE_SYSTEM );
// insert SYSTEM entry
OUString aDefaultCurr = m_sSystemDefaultString + " - " + rCurr.GetBankSymbol();
- m_xCurrencyLB->append_text(aDefaultCurr);
+ m_xCurrencyLB->append("default", aDefaultCurr);
+ assert(m_xCurrencyLB->find_id("default") != -1);
// all currencies
OUString aTwoSpace( " " );
sal_uInt16 nCurrCount = rCurrTab.size();
@@ -1708,9 +1709,10 @@ IMPL_LINK_NOARG(OfaLanguagesTabPage, LocaleSettingHdl, weld::ComboBox&, void)
const NfCurrencyEntry& rCurr = SvNumberFormatter::GetCurrencyEntry(
(eLang == LANGUAGE_USER_SYSTEM_CONFIG) ? MsLangId::getSystemLanguage() : eLang);
// Update the "Default ..." currency.
- m_xCurrencyLB->remove_id("");
+ m_xCurrencyLB->remove_id("default");
OUString aDefaultCurr = m_sSystemDefaultString + " - " + rCurr.GetBankSymbol();
- m_xCurrencyLB->append_text(aDefaultCurr);
+ m_xCurrencyLB->append("default", aDefaultCurr);
+ assert(m_xCurrencyLB->find_id("default") != -1);
m_xCurrencyLB->set_active_text(aDefaultCurr);
// obtain corresponding locale data
More information about the Libreoffice-commits
mailing list