summaryrefslogtreecommitdiff
path: root/sc/source/ui/optdlg
diff options
context:
space:
mode:
authorMike Kaganski <mike.kaganski@collabora.com>2018-11-06 14:37:23 +0300
committerMike Kaganski <mike.kaganski@collabora.com>2018-11-08 12:15:51 +0100
commit9e0770ea7e0cf094add54ad64bc9ff825d24bbe1 (patch)
treee897291e44ecb11ca44ba5e5ebefe03ac536862f /sc/source/ui/optdlg
parent841ee6fb052fb35467d74b70f575a86c8c0fe3b7 (diff)
Convert FieldUnit to scoped enum
Change-Id: Id2df31daa596a18c79af5fc6ea162deb6e24d5af Reviewed-on: https://gerrit.libreoffice.org/62958 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'sc/source/ui/optdlg')
-rw-r--r--sc/source/ui/optdlg/tpview.cxx18
1 files changed, 9 insertions, 9 deletions
diff --git a/sc/source/ui/optdlg/tpview.cxx b/sc/source/ui/optdlg/tpview.cxx
index 0fca706f38e2..77e89cda1c72 100644
--- a/sc/source/ui/optdlg/tpview.cxx
+++ b/sc/source/ui/optdlg/tpview.cxx
@@ -370,11 +370,11 @@ ScTpLayoutOptions::ScTpLayoutOptions( vcl::Window* pParent,
switch ( eFUnit )
{
- case FUNIT_MM:
- case FUNIT_CM:
- case FUNIT_POINT:
- case FUNIT_PICA:
- case FUNIT_INCH:
+ case FieldUnit::MM:
+ case FieldUnit::CM:
+ case FieldUnit::POINT:
+ case FieldUnit::PICA:
+ case FieldUnit::INCH:
{
// only use these metrics
sal_Int32 nPos = m_pUnitLB->InsertEntry( sMetric );
@@ -440,7 +440,7 @@ bool ScTpLayoutOptions::FillItemSet( SfxItemSet* rCoreSet )
if(m_pTabMF->IsValueChangedFromSaved())
{
rCoreSet->Put(SfxUInt16Item(SID_ATTR_DEFTABSTOP,
- sal::static_int_cast<sal_uInt16>( m_pTabMF->Denormalize(m_pTabMF->GetValue(FUNIT_TWIP)) )));
+ sal::static_int_cast<sal_uInt16>( m_pTabMF->Denormalize(m_pTabMF->GetValue(FieldUnit::TWIP)) )));
bRet = true;
}
@@ -550,7 +550,7 @@ void ScTpLayoutOptions::Reset( const SfxItemSet* rCoreSet )
const SfxPoolItem* pItem;
if(SfxItemState::SET == rCoreSet->GetItemState(SID_ATTR_DEFTABSTOP, false, &pItem))
- m_pTabMF->SetValue(m_pTabMF->Normalize(static_cast<const SfxUInt16Item*>(pItem)->GetValue()), FUNIT_TWIP);
+ m_pTabMF->SetValue(m_pTabMF->Normalize(static_cast<const SfxUInt16Item*>(pItem)->GetValue()), FieldUnit::TWIP);
m_pTabMF->SaveValue();
m_pUnitLB ->SaveValue();
@@ -647,9 +647,9 @@ IMPL_LINK_NOARG(ScTpLayoutOptions, MetricHdl, ListBox&, void)
{
FieldUnit eFieldUnit = static_cast<FieldUnit>(reinterpret_cast<sal_IntPtr>(m_pUnitLB->GetEntryData( nMPos )));
sal_Int64 nVal =
- m_pTabMF->Denormalize( m_pTabMF->GetValue( FUNIT_TWIP ) );
+ m_pTabMF->Denormalize( m_pTabMF->GetValue( FieldUnit::TWIP ) );
::SetFieldUnit( *m_pTabMF, eFieldUnit );
- m_pTabMF->SetValue( m_pTabMF->Normalize( nVal ), FUNIT_TWIP );
+ m_pTabMF->SetValue( m_pTabMF->Normalize( nVal ), FieldUnit::TWIP );
}
}