[Libreoffice-commits] core.git: Branch 'libreoffice-7-0' - cui/source
Heiko Tietze (via logerrit)
logerrit at kemper.freedesktop.org
Wed Sep 2 05:38:00 UTC 2020
cui/source/dialogs/tipofthedaydlg.cxx | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
New commits:
commit e21768ce2898453226aedd5f8ce19d8075f5bec5
Author: Heiko Tietze <tietze.heiko at gmail.com>
AuthorDate: Mon Aug 31 11:38:35 2020 +0200
Commit: Heiko Tietze <heiko.tietze at documentfoundation.org>
CommitDate: Wed Sep 2 07:37:25 2020 +0200
Resolves tdf#135790 - Support for multiple %MOD1/2 entries
While loop added
Change-Id: I81386bb23381e5248f3c045ad2b998a92346ec34
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101700
Tested-by: Jenkins
Reviewed-by: Heiko Tietze <heiko.tietze at documentfoundation.org>
(cherry picked from commit db5f204b1d3d96975d902b587d6d18bc06610eea)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101860
diff --git a/cui/source/dialogs/tipofthedaydlg.cxx b/cui/source/dialogs/tipofthedaydlg.cxx
index 7d6a05b72a0f..4775ed0578b9 100644
--- a/cui/source/dialogs/tipofthedaydlg.cxx
+++ b/cui/source/dialogs/tipofthedaydlg.cxx
@@ -89,11 +89,17 @@ void TipOfTheDayDialog::UpdateTip()
#endif
sal_Int32 aPos;
aPos = aText.indexOf("%MOD1");
- if (aPos != -1)
+ while (aPos != -1)
+ {
aText = aText.replaceAt(aPos, 5, aMOD1);
+ aPos = aText.indexOf("%MOD1");
+ }
aPos = aText.indexOf("%MOD2");
- if (aPos != -1)
+ while (aPos != -1)
+ {
aText = aText.replaceAt(aPos, 5, aMOD2);
+ aPos = aText.indexOf("%MOD2");
+ }
m_pText->set_label(aText);
// hyperlink
More information about the Libreoffice-commits
mailing list