summaryrefslogtreecommitdiff
path: root/sw/source/ui/config
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2020-04-24 12:06:55 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2020-04-24 14:18:23 +0200
commita910081e0634120118d6f32996591928677d504f (patch)
tree186345c33254ca7b7a55e0ec664070acb69970bf /sw/source/ui/config
parent2be4afe53a94fc051aae9ba9b20443f7a350fb18 (diff)
convert SwFillMode to scoped enum
Change-Id: I03230496aac57f8855ce8d3dcd8576d265060aa6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92845 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sw/source/ui/config')
-rw-r--r--sw/source/ui/config/optpage.cxx11
1 files changed, 5 insertions, 6 deletions
diff --git a/sw/source/ui/config/optpage.cxx b/sw/source/ui/config/optpage.cxx
index 0d51258fb730..7c6140ea3a6c 100644
--- a/sw/source/ui/config/optpage.cxx
+++ b/sw/source/ui/config/optpage.cxx
@@ -1202,7 +1202,7 @@ SwShdwCursorOptionsTabPage::SwShdwCursorOptionsTabPage(weld::Container* pPage, w
, m_xMathBaselineAlignmentCB(m_xBuilder->weld_check_button("mathbaseline"))
{
const SfxPoolItem* pItem = nullptr;
- sal_uInt8 eMode = SwFillMode::FILL_TAB;
+ SwFillMode eMode = SwFillMode::Tab;
bool bIsOn = false;
if( SfxItemState::SET == rSet.GetItemState( FN_PARAM_SHADOWCURSOR, false, &pItem ))
@@ -1213,7 +1213,7 @@ SwShdwCursorOptionsTabPage::SwShdwCursorOptionsTabPage(weld::Container* pPage, w
}
m_xOnOffCB->set_active( bIsOn );
- m_xDirectCursorFillMode->set_active( eMode );
+ m_xDirectCursorFillMode->set_active( static_cast<int>(eMode) );
if(SfxItemState::SET != rSet.GetItemState(SID_HTML_MODE, false, &pItem )
|| !(static_cast<const SfxUInt16Item*>(pItem)->GetValue() & HTMLMODE_ON))
return;
@@ -1252,8 +1252,7 @@ bool SwShdwCursorOptionsTabPage::FillItemSet( SfxItemSet* rSet )
SwShadowCursorItem aOpt;
aOpt.SetOn( m_xOnOffCB->get_active() );
- sal_uInt8 eMode;
- eMode = m_xDirectCursorFillMode->get_active();
+ SwFillMode eMode = static_cast<SwFillMode>(m_xDirectCursorFillMode->get_active());
aOpt.SetMode( eMode );
bool bRet = false;
@@ -1301,7 +1300,7 @@ bool SwShdwCursorOptionsTabPage::FillItemSet( SfxItemSet* rSet )
void SwShdwCursorOptionsTabPage::Reset( const SfxItemSet* rSet )
{
const SfxPoolItem* pItem = nullptr;
- sal_uInt8 eMode = SwFillMode::FILL_TAB;
+ SwFillMode eMode = SwFillMode::Tab;
bool bIsOn = false;
if( SfxItemState::SET == rSet->GetItemState( FN_PARAM_SHADOWCURSOR, false, &pItem ))
@@ -1312,7 +1311,7 @@ void SwShdwCursorOptionsTabPage::Reset( const SfxItemSet* rSet )
}
m_xOnOffCB->set_active( bIsOn );
- m_xDirectCursorFillMode->set_active( eMode );
+ m_xDirectCursorFillMode->set_active( static_cast<int>(eMode) );
if (m_pWrtShell) {
m_xMathBaselineAlignmentCB->set_active( m_pWrtShell->GetDoc()->getIDocumentSettingAccess().get( DocumentSettingId::MATH_BASELINE_ALIGNMENT ) );
m_xMathBaselineAlignmentCB->save_state();