summaryrefslogtreecommitdiff
path: root/editeng
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2016-08-15 14:47:51 +0200
committerNoel Grandin <noel@peralex.com>2016-08-17 08:45:15 +0200
commitfd0e67ce0d8cf84470b1414009ed1e0f81410b0f (patch)
tree40894cd63c18eb7c8967f1158c33c15f6069aac9 /editeng
parent95be297746fda812f5a64e5fd53c753dfd9b249c (diff)
convert SvxCellJustifyMethod to scoped enum
Change-Id: Ifdb9192f6556477a28af05a74042f216d4e9e8fd
Diffstat (limited to 'editeng')
-rw-r--r--editeng/source/editeng/eerdll.cxx2
-rw-r--r--editeng/source/editeng/impedit3.cxx2
-rw-r--r--editeng/source/items/justifyitem.cxx12
3 files changed, 8 insertions, 8 deletions
diff --git a/editeng/source/editeng/eerdll.cxx b/editeng/source/editeng/eerdll.cxx
index 89d1b84e9f40..a6e79f48ec97 100644
--- a/editeng/source/editeng/eerdll.cxx
+++ b/editeng/source/editeng/eerdll.cxx
@@ -121,7 +121,7 @@ SfxPoolItem** GlobalEditData::GetDefItems()
ppDefItems[13] = new SvxLineSpacingItem( 0, EE_PARA_SBL );
ppDefItems[14] = new SvxAdjustItem( SVX_ADJUST_LEFT, EE_PARA_JUST );
ppDefItems[15] = new SvxTabStopItem( 0, 0, SVX_TAB_ADJUST_LEFT, EE_PARA_TABS );
- ppDefItems[16] = new SvxJustifyMethodItem( SVX_JUSTIFY_METHOD_AUTO, EE_PARA_JUST_METHOD );
+ ppDefItems[16] = new SvxJustifyMethodItem( SvxCellJustifyMethod::Auto, EE_PARA_JUST_METHOD );
ppDefItems[17] = new SvxVerJustifyItem( SVX_VER_JUSTIFY_STANDARD, EE_PARA_VER_JUST );
// Character attributes:
diff --git a/editeng/source/editeng/impedit3.cxx b/editeng/source/editeng/impedit3.cxx
index d31ecbe95427..bf52ede29ad4 100644
--- a/editeng/source/editeng/impedit3.cxx
+++ b/editeng/source/editeng/impedit3.cxx
@@ -1430,7 +1430,7 @@ bool ImpEditEngine::CreateLines( sal_Int32 nPara, sal_uInt32 nStartPosY )
break;
case SVX_ADJUST_BLOCK:
{
- bool bDistLastLine = (GetJustifyMethod(nPara) == SVX_JUSTIFY_METHOD_DISTRIBUTE);
+ bool bDistLastLine = (GetJustifyMethod(nPara) == SvxCellJustifyMethod::Distribute);
long nRemainingSpace = nMaxLineWidth - aTextSize.Width();
pLine->SetStartPosX( nStartX );
if ( nRemainingSpace > 0 && (!bEOC || bDistLastLine) )
diff --git a/editeng/source/items/justifyitem.cxx b/editeng/source/items/justifyitem.cxx
index 0aa568f3984a..48f961aab56d 100644
--- a/editeng/source/items/justifyitem.cxx
+++ b/editeng/source/items/justifyitem.cxx
@@ -345,8 +345,8 @@ bool SvxJustifyMethodItem::QueryValue( uno::Any& rVal, sal_uInt8 /*nMemberId*/ )
sal_Int32 nUno = table::CellJustifyMethod::AUTO;
switch (static_cast<SvxCellJustifyMethod>(GetValue()))
{
- case SVX_JUSTIFY_METHOD_AUTO: nUno = table::CellJustifyMethod::AUTO; break;
- case SVX_JUSTIFY_METHOD_DISTRIBUTE: nUno = table::CellJustifyMethod::DISTRIBUTE; break;
+ case SvxCellJustifyMethod::Auto: nUno = table::CellJustifyMethod::AUTO; break;
+ case SvxCellJustifyMethod::Distribute: nUno = table::CellJustifyMethod::DISTRIBUTE; break;
default:;
}
rVal <<= nUno;
@@ -359,14 +359,14 @@ bool SvxJustifyMethodItem::PutValue( const uno::Any& rVal, sal_uInt8 /*nMemberId
if (!(rVal >>= nVal))
return false;
- SvxCellJustifyMethod eSvx = SVX_JUSTIFY_METHOD_AUTO;
+ SvxCellJustifyMethod eSvx = SvxCellJustifyMethod::Auto;
switch (nVal)
{
case table::CellJustifyMethod::AUTO:
- eSvx = SVX_JUSTIFY_METHOD_AUTO;
+ eSvx = SvxCellJustifyMethod::Auto;
break;
case table::CellJustifyMethod::DISTRIBUTE:
- eSvx = SVX_JUSTIFY_METHOD_DISTRIBUTE;
+ eSvx = SvxCellJustifyMethod::Distribute;
break;
default:;
}
@@ -398,7 +398,7 @@ SfxPoolItem* SvxJustifyMethodItem::Create( SvStream& rStream, sal_uInt16 ) const
sal_uInt16 SvxJustifyMethodItem::GetValueCount() const
{
- return SVX_JUSTIFY_METHOD_DISTRIBUTE + 1; // Last Enum value + 1
+ return (sal_uInt16)SvxCellJustifyMethod::Distribute + 1; // Last Enum value + 1
}
SvxJustifyMethodItem& SvxJustifyMethodItem::operator=(const SvxJustifyMethodItem& r)