diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-03-17 14:15:30 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-03-20 06:52:34 +0000 |
commit | d99d143900081dd14e070c7373ba204739d80496 (patch) | |
tree | 72fb5e8523e29399d0aff96d3a6fb37dafeaabd6 /sw/source/uibase/frmdlg/frmmgr.cxx | |
parent | 8e5437ea859e78f7de2730bfa60ab6d27534f286 (diff) |
convert RndStdIds to scoped enum
Change-Id: I029ad67dfcbc40f3953adf485957efcbd97f23d0
Reviewed-on: https://gerrit.libreoffice.org/35328
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sw/source/uibase/frmdlg/frmmgr.cxx')
-rw-r--r-- | sw/source/uibase/frmdlg/frmmgr.cxx | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/sw/source/uibase/frmdlg/frmmgr.cxx b/sw/source/uibase/frmdlg/frmmgr.cxx index 0f91925b7e9b..7d32a309cf82 100644 --- a/sw/source/uibase/frmdlg/frmmgr.cxx +++ b/sw/source/uibase/frmdlg/frmmgr.cxx @@ -181,11 +181,11 @@ void SwFlyFrameAttrMgr::InsertFlyFrame(RndStdIds eAnchorType, const Point &rPos, const Size &rSize ) { - OSL_ENSURE( eAnchorType == FLY_AT_PAGE || - eAnchorType == FLY_AT_PARA || - eAnchorType == FLY_AT_CHAR || - eAnchorType == FLY_AT_FLY || - eAnchorType == FLY_AS_CHAR, "invalid frame type" ); + OSL_ENSURE( eAnchorType == RndStdIds::FLY_AT_PAGE || + eAnchorType == RndStdIds::FLY_AT_PARA || + eAnchorType == RndStdIds::FLY_AT_CHAR || + eAnchorType == RndStdIds::FLY_AT_FLY || + eAnchorType == RndStdIds::FLY_AS_CHAR, "invalid frame type" ); SetPos( rPos ); @@ -201,8 +201,8 @@ void SwFlyFrameAttrMgr::SetAnchor( RndStdIds eId ) m_pOwnSh->GetPageNum( nPhyPageNum, nVirtPageNum ); m_aSet.Put( SwFormatAnchor( eId, nPhyPageNum ) ); - if ((FLY_AT_PAGE == eId) || (FLY_AT_PARA == eId) || (FLY_AT_CHAR == eId) - || (FLY_AT_FLY == eId)) + if ((RndStdIds::FLY_AT_PAGE == eId) || (RndStdIds::FLY_AT_PARA == eId) || (RndStdIds::FLY_AT_CHAR == eId) + || (RndStdIds::FLY_AT_FLY == eId)) { SwFormatVertOrient aVertOrient( GetVertOrient() ); SwFormatHoriOrient aHoriOrient( GetHoriOrient() ); @@ -277,7 +277,7 @@ void SwFlyFrameAttrMgr::ValidateMetrics( SvxSwFrameValidation& rVal, rVal.nWidth = rVal.nHeight; rVal.nHeight = nTmp; } - if ((eAnchorType == FLY_AT_PAGE) || (eAnchorType == FLY_AT_FLY)) + if ((eAnchorType == RndStdIds::FLY_AT_PAGE) || (eAnchorType == RndStdIds::FLY_AT_FLY)) { // MinimalPosition rVal.nMinHPos = aBoundRect.Left(); @@ -327,8 +327,8 @@ void SwFlyFrameAttrMgr::ValidateMetrics( SvxSwFrameValidation& rVal, } // OD 12.11.2003 #i22341# - handle to character anchored objects vertical // aligned at character or top of line in a special case - else if ((eAnchorType == FLY_AT_PARA) || - ((eAnchorType == FLY_AT_CHAR) && + else if ((eAnchorType == RndStdIds::FLY_AT_PARA) || + ((eAnchorType == RndStdIds::FLY_AT_CHAR) && !(rVal.nVRelOrient == text::RelOrientation::CHAR) && !(rVal.nVRelOrient == text::RelOrientation::TEXT_LINE) ) ) { @@ -395,7 +395,7 @@ void SwFlyFrameAttrMgr::ValidateMetrics( SvxSwFrameValidation& rVal, // vertical aligned at character or top of line. // Note: (1) positive vertical values are positions above the top of line // (2) negative vertical values are positions below the top of line - else if ( (eAnchorType == FLY_AT_CHAR) && + else if ( (eAnchorType == RndStdIds::FLY_AT_CHAR) && ( rVal.nVRelOrient == text::RelOrientation::CHAR || rVal.nVRelOrient == text::RelOrientation::TEXT_LINE ) ) { @@ -442,7 +442,7 @@ void SwFlyFrameAttrMgr::ValidateMetrics( SvxSwFrameValidation& rVal, rVal.nMaxHeight = aBoundRect.Height(); } } - else if ( eAnchorType == FLY_AS_CHAR ) + else if ( eAnchorType == RndStdIds::FLY_AS_CHAR ) { rVal.nMinHPos = 0; rVal.nMaxHPos = 0; |