[Libreoffice-commits] core.git: cui/source
Libreoffice Gerrit user
logerrit at kemper.freedesktop.org
Mon Jan 14 13:22:51 UTC 2019
cui/source/tabpages/autocdlg.cxx | 24 ++++++++++++------------
1 file changed, 12 insertions(+), 12 deletions(-)
New commits:
commit 8aa5abf3aaae062ae41a4d2f122170da9e31cf67
Author: Caolán McNamara <caolanm at redhat.com>
AuthorDate: Mon Jan 14 10:08:08 2019 +0000
Commit: Caolán McNamara <caolanm at redhat.com>
CommitDate: Mon Jan 14 14:22:29 2019 +0100
Resolves: tdf#122627 be explicit about what column to check
Change-Id: Icdd1cef6b0bc9d8dd61c309dc9de66021fc9422d
Reviewed-on: https://gerrit.libreoffice.org/66286
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/tabpages/autocdlg.cxx b/cui/source/tabpages/autocdlg.cxx
index add6fb72f3cf..3d177683458d 100644
--- a/cui/source/tabpages/autocdlg.cxx
+++ b/cui/source/tabpages/autocdlg.cxx
@@ -245,6 +245,10 @@ void OfaAutocorrOptionsPage::InsertEntry(const OUString& rTxt)
m_xCheckLB->set_text(nRow, rTxt, 1);
}
+#define CBCOL_FIRST 0
+#define CBCOL_SECOND 1
+#define CBCOL_BOTH 2
+
void OfaAutocorrOptionsPage::Reset( const SfxItemSet* )
{
SvxAutoCorrect* pAutoCorrect = SvxAutoCorrCfg::Get().GetAutoCorrect();
@@ -263,14 +267,14 @@ void OfaAutocorrOptionsPage::Reset( const SfxItemSet* )
InsertEntry(m_sAccidentalCaps);
int nPos = 0;
- m_xCheckLB->set_toggle( nPos++, bool(nFlags & ACFlags::Autocorrect) );
- m_xCheckLB->set_toggle( nPos++, bool(nFlags & ACFlags::CapitalStartWord) );
- m_xCheckLB->set_toggle( nPos++, bool(nFlags & ACFlags::CapitalStartSentence) );
- m_xCheckLB->set_toggle( nPos++, bool(nFlags & ACFlags::ChgWeightUnderl) );
- m_xCheckLB->set_toggle( nPos++, bool(nFlags & ACFlags::SetINetAttr) );
- m_xCheckLB->set_toggle( nPos++, bool(nFlags & ACFlags::ChgToEnEmDash) );
- m_xCheckLB->set_toggle( nPos++, bool(nFlags & ACFlags::IgnoreDoubleSpace) );
- m_xCheckLB->set_toggle( nPos++, bool(nFlags & ACFlags::CorrectCapsLock) );
+ m_xCheckLB->set_toggle( nPos++, bool(nFlags & ACFlags::Autocorrect), CBCOL_FIRST );
+ m_xCheckLB->set_toggle( nPos++, bool(nFlags & ACFlags::CapitalStartWord), CBCOL_FIRST );
+ m_xCheckLB->set_toggle( nPos++, bool(nFlags & ACFlags::CapitalStartSentence), CBCOL_FIRST );
+ m_xCheckLB->set_toggle( nPos++, bool(nFlags & ACFlags::ChgWeightUnderl), CBCOL_FIRST );
+ m_xCheckLB->set_toggle( nPos++, bool(nFlags & ACFlags::SetINetAttr), CBCOL_FIRST );
+ m_xCheckLB->set_toggle( nPos++, bool(nFlags & ACFlags::ChgToEnEmDash), CBCOL_FIRST );
+ m_xCheckLB->set_toggle( nPos++, bool(nFlags & ACFlags::IgnoreDoubleSpace), CBCOL_FIRST );
+ m_xCheckLB->set_toggle( nPos++, bool(nFlags & ACFlags::CorrectCapsLock), CBCOL_FIRST );
m_xCheckLB->thaw();
}
@@ -319,10 +323,6 @@ public:
/* */
/*********************************************************************/
-#define CBCOL_FIRST 0
-#define CBCOL_SECOND 1
-#define CBCOL_BOTH 2
-
enum OfaAutoFmtOptions
{
USE_REPLACE_TABLE,
More information about the Libreoffice-commits
mailing list