diff options
author | Miklos Vajna <vmiklos@collabora.co.uk> | 2014-02-08 16:58:12 +0100 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2014-02-08 17:00:56 +0100 |
commit | bbe6ea29856f5a5e2aeb87334a86bf8e3193dc23 (patch) | |
tree | 40d3417cfaa5476931696f2a4bc4423dca954bff /sw | |
parent | e4f982f583816c9702d926ebe2ca1e97eb3bd4e1 (diff) |
SwFlyFrmAttrMgr: rename member variables missing their prefixes
Change-Id: I044168d7102b7c970ff5dd454c74262af7f3ac62
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/ui/frmdlg/frmmgr.cxx | 140 | ||||
-rw-r--r-- | sw/source/ui/inc/frmmgr.hxx | 36 |
2 files changed, 88 insertions, 88 deletions
diff --git a/sw/source/ui/frmdlg/frmmgr.cxx b/sw/source/ui/frmdlg/frmmgr.cxx index ab4085cd19bd..c271907c0baa 100644 --- a/sw/source/ui/frmdlg/frmmgr.cxx +++ b/sw/source/ui/frmdlg/frmmgr.cxx @@ -55,14 +55,14 @@ static sal_uInt16 aFrmMgrRange[] = { Description: determine frame attributes via Shell --------------------------------------------------------------------*/ SwFlyFrmAttrMgr::SwFlyFrmAttrMgr( sal_Bool bNew, SwWrtShell* pSh, sal_uInt8 nType ) : - aSet( (SwAttrPool&)pSh->GetAttrPool(), aFrmMgrRange ), - pOwnSh( pSh ), - bAbsPos( sal_False ), - bNewFrm( bNew ), - bIsInVertical( sal_False ), - bIsInVerticalL2R( sal_False ) + m_aSet( (SwAttrPool&)pSh->GetAttrPool(), aFrmMgrRange ), + m_pOwnSh( pSh ), + m_bAbsPos( sal_False ), + m_bNewFrm( bNew ), + m_bIsInVertical( sal_False ), + m_bIsInVerticalL2R( sal_False ) { - if ( bNewFrm ) + if ( m_bNewFrm ) { // set defaults: sal_uInt16 nId = 0; @@ -72,32 +72,32 @@ SwFlyFrmAttrMgr::SwFlyFrmAttrMgr( sal_Bool bNew, SwWrtShell* pSh, sal_uInt8 nTyp case FRMMGR_TYPE_OLE: nId = RES_POOLFRM_OLE; break; case FRMMGR_TYPE_GRF: nId = RES_POOLFRM_GRAPHIC; break; } - aSet.SetParent( &pOwnSh->GetFmtFromPool( nId )->GetAttrSet()); - aSet.Put( SwFmtFrmSize( ATT_MIN_SIZE, DFLT_WIDTH, DFLT_HEIGHT )); + m_aSet.SetParent( &m_pOwnSh->GetFmtFromPool( nId )->GetAttrSet()); + m_aSet.Put( SwFmtFrmSize( ATT_MIN_SIZE, DFLT_WIDTH, DFLT_HEIGHT )); if ( 0 != ::GetHtmlMode(pSh->GetView().GetDocShell()) ) - aSet.Put( SwFmtHoriOrient( 0, text::HoriOrientation::LEFT, text::RelOrientation::PRINT_AREA ) ); + m_aSet.Put( SwFmtHoriOrient( 0, text::HoriOrientation::LEFT, text::RelOrientation::PRINT_AREA ) ); } else if ( nType == FRMMGR_TYPE_NONE ) { - pOwnSh->GetFlyFrmAttr( aSet ); + m_pOwnSh->GetFlyFrmAttr( m_aSet ); sal_Bool bRightToLeft; - bIsInVertical = pOwnSh->IsFrmVertical(sal_True, bRightToLeft, bIsInVerticalL2R); + m_bIsInVertical = m_pOwnSh->IsFrmVertical(sal_True, bRightToLeft, m_bIsInVerticalL2R); } - ::PrepareBoxInfo( aSet, *pOwnSh ); + ::PrepareBoxInfo( m_aSet, *m_pOwnSh ); } SwFlyFrmAttrMgr::SwFlyFrmAttrMgr( sal_Bool bNew, SwWrtShell* pSh, const SfxItemSet &rSet ) : - aSet( rSet ), - pOwnSh( pSh ), - bAbsPos( sal_False ), - bNewFrm( bNew ), - bIsInVertical(sal_False), - bIsInVerticalL2R(sal_False) + m_aSet( rSet ), + m_pOwnSh( pSh ), + m_bAbsPos( sal_False ), + m_bNewFrm( bNew ), + m_bIsInVertical(sal_False), + m_bIsInVerticalL2R(sal_False) { if(!bNew) { sal_Bool bRightToLeft; - bIsInVertical = pSh->IsFrmVertical(sal_True, bRightToLeft, bIsInVerticalL2R); + m_bIsInVertical = pSh->IsFrmVertical(sal_True, bRightToLeft, m_bIsInVerticalL2R); } } @@ -106,24 +106,24 @@ SwFlyFrmAttrMgr::SwFlyFrmAttrMgr( sal_Bool bNew, SwWrtShell* pSh, const SfxItemS --------------------------------------------------------------------*/ void SwFlyFrmAttrMgr::UpdateAttrMgr() { - if ( !bNewFrm && pOwnSh->IsFrmSelected() ) - pOwnSh->GetFlyFrmAttr( aSet ); - ::PrepareBoxInfo( aSet, *pOwnSh ); + if ( !m_bNewFrm && m_pOwnSh->IsFrmSelected() ) + m_pOwnSh->GetFlyFrmAttr( m_aSet ); + ::PrepareBoxInfo( m_aSet, *m_pOwnSh ); } void SwFlyFrmAttrMgr::_UpdateFlyFrm() { const SfxPoolItem* pItem = 0; - if (aSet.GetItemState(FN_SET_FRM_NAME, sal_False, &pItem) == SFX_ITEM_SET) - pOwnSh->SetFlyName(((SfxStringItem *)pItem)->GetValue()); + if (m_aSet.GetItemState(FN_SET_FRM_NAME, sal_False, &pItem) == SFX_ITEM_SET) + m_pOwnSh->SetFlyName(((SfxStringItem *)pItem)->GetValue()); - pOwnSh->SetModified(); + m_pOwnSh->SetModified(); - if ( bAbsPos ) + if ( m_bAbsPos ) { - pOwnSh->SetFlyPos( aAbsPos ); - bAbsPos = sal_False; + m_pOwnSh->SetFlyPos( m_aAbsPos ); + m_bAbsPos = sal_False; } } @@ -132,30 +132,30 @@ void SwFlyFrmAttrMgr::_UpdateFlyFrm() --------------------------------------------------------------------*/ void SwFlyFrmAttrMgr::UpdateFlyFrm() { - OSL_ENSURE( pOwnSh->IsFrmSelected(), + OSL_ENSURE( m_pOwnSh->IsFrmSelected(), "no frame selected or no shell, update not possible"); - if( pOwnSh->IsFrmSelected() ) + if( m_pOwnSh->IsFrmSelected() ) { //JP 6.8.2001: set never an invalid anchor into the core. const SfxPoolItem *pGItem, *pItem; - if( SFX_ITEM_SET == aSet.GetItemState( RES_ANCHOR, sal_False, &pItem )) + if( SFX_ITEM_SET == m_aSet.GetItemState( RES_ANCHOR, sal_False, &pItem )) { - SfxItemSet aGetSet( *aSet.GetPool(), RES_ANCHOR, RES_ANCHOR ); - if( pOwnSh->GetFlyFrmAttr( aGetSet ) && 1 == aGetSet.Count() && + SfxItemSet aGetSet( *m_aSet.GetPool(), RES_ANCHOR, RES_ANCHOR ); + if( m_pOwnSh->GetFlyFrmAttr( aGetSet ) && 1 == aGetSet.Count() && SFX_ITEM_SET == aGetSet.GetItemState( RES_ANCHOR, sal_False, &pGItem ) && ((SwFmtAnchor*)pGItem)->GetAnchorId() == ((SwFmtAnchor*)pItem)->GetAnchorId() ) - aSet.ClearItem( RES_ANCHOR ); + m_aSet.ClearItem( RES_ANCHOR ); } // return wg. BASIC - if( aSet.Count() ) + if( m_aSet.Count() ) { - pOwnSh->StartAllAction(); - pOwnSh->SetFlyFrmAttr( aSet ); + m_pOwnSh->StartAllAction(); + m_pOwnSh->SetFlyFrmAttr( m_aSet ); _UpdateFlyFrm(); - pOwnSh->EndAllAction(); + m_pOwnSh->EndAllAction(); } } } @@ -165,18 +165,18 @@ void SwFlyFrmAttrMgr::UpdateFlyFrm() --------------------------------------------------------------------*/ sal_Bool SwFlyFrmAttrMgr::InsertFlyFrm() { - pOwnSh->StartAllAction(); + m_pOwnSh->StartAllAction(); - sal_Bool bRet = 0 != pOwnSh->NewFlyFrm( aSet ); + sal_Bool bRet = 0 != m_pOwnSh->NewFlyFrm( m_aSet ); // turn on the right mode at the shell, frame got selected automatically. if ( bRet ) { _UpdateFlyFrm(); - pOwnSh->EnterSelFrmMode(); - FrameNotify(pOwnSh, FLY_DRAG_START); + m_pOwnSh->EnterSelFrmMode(); + FrameNotify(m_pOwnSh, FLY_DRAG_START); } - pOwnSh->EndAllAction(); + m_pOwnSh->EndAllAction(); return bRet; } @@ -212,9 +212,9 @@ void SwFlyFrmAttrMgr::InsertFlyFrm(RndStdIds eAnchorType, void SwFlyFrmAttrMgr::SetAnchor( RndStdIds eId ) { sal_uInt16 nPhyPageNum, nVirtPageNum; - pOwnSh->GetPageNum( nPhyPageNum, nVirtPageNum ); + m_pOwnSh->GetPageNum( nPhyPageNum, nVirtPageNum ); - aSet.Put( SwFmtAnchor( eId, nPhyPageNum ) ); + m_aSet.Put( SwFmtAnchor( eId, nPhyPageNum ) ); if ((FLY_AT_PAGE == eId) || (FLY_AT_PARA == eId) || (FLY_AT_CHAR == eId) || (FLY_AT_FLY == eId)) { @@ -222,8 +222,8 @@ void SwFlyFrmAttrMgr::SetAnchor( RndStdIds eId ) SwFmtHoriOrient aHoriOrient( GetHoriOrient() ); aHoriOrient.SetRelationOrient( text::RelOrientation::FRAME ); aVertOrient.SetRelationOrient( text::RelOrientation::FRAME ); - aSet.Put( aVertOrient ); - aSet.Put( aHoriOrient ); + m_aSet.Put( aVertOrient ); + m_aSet.Put( aHoriOrient ); } } @@ -232,7 +232,7 @@ void SwFlyFrmAttrMgr::SetAnchor( RndStdIds eId ) ------------------------------------------------------------------------*/ void SwFlyFrmAttrMgr::SetCol( const SwFmtCol &rCol ) { - aSet.Put( rCol ); + m_aSet.Put( rCol ); } /*-------------------------------------------------------------------- @@ -240,15 +240,15 @@ void SwFlyFrmAttrMgr::SetCol( const SwFmtCol &rCol ) --------------------------------------------------------------------*/ void SwFlyFrmAttrMgr::SetAbsPos( const Point& rPoint ) { - bAbsPos = sal_True; - aAbsPos = rPoint; + m_bAbsPos = sal_True; + m_aAbsPos = rPoint; SwFmtVertOrient aVertOrient( GetVertOrient() ); SwFmtHoriOrient aHoriOrient( GetHoriOrient() ); aHoriOrient.SetHoriOrient( text::HoriOrientation::NONE ); aVertOrient.SetVertOrient( text::VertOrientation::NONE ); - aSet.Put( aVertOrient ); - aSet.Put( aHoriOrient ); + m_aSet.Put( aVertOrient ); + m_aSet.Put( aHoriOrient ); } /*-------------------------------------------------------------------- @@ -269,8 +269,8 @@ void SwFlyFrmAttrMgr::ValidateMetrics( SvxSwFrameValidation& rVal, // OD 18.09.2003 #i18732# - adjustment for allowing vertical position // aligned to page for fly frame anchored to paragraph or to character. const RndStdIds eAnchorType = static_cast<RndStdIds >(rVal.nAnchorType); - const SwFmtFrmSize& rSize = (const SwFmtFrmSize&)aSet.Get(RES_FRM_SIZE); - pOwnSh->CalcBoundRect( aBoundRect, eAnchorType, + const SwFmtFrmSize& rSize = (const SwFmtFrmSize&)m_aSet.Get(RES_FRM_SIZE); + m_pOwnSh->CalcBoundRect( aBoundRect, eAnchorType, rVal.nHRelOrient, rVal.nVRelOrient, pToCharCntntPos, @@ -282,7 +282,7 @@ void SwFlyFrmAttrMgr::ValidateMetrics( SvxSwFrameValidation& rVal, return; // --> OD 2009-09-01 #mongolianlayout# - if ( bIsInVertical || bIsInVerticalL2R ) + if ( m_bIsInVertical || m_bIsInVerticalL2R ) { Point aPos(aBoundRect.Pos()); long nTmp = aPos.X(); @@ -480,7 +480,7 @@ void SwFlyFrmAttrMgr::ValidateMetrics( SvxSwFrameValidation& rVal, } } // --> OD 2009-09-01 #mongolianlayout# - if ( bIsInVertical || bIsInVerticalL2R ) + if ( m_bIsInVertical || m_bIsInVerticalL2R ) { //restore width/height exchange long nTmp = rVal.nWidth; @@ -530,31 +530,31 @@ SwTwips SwFlyFrmAttrMgr::CalcRightSpace() --------------------------------------------------------------------*/ void SwFlyFrmAttrMgr::DelAttr( sal_uInt16 nId ) { - aSet.ClearItem( nId ); + m_aSet.ClearItem( nId ); } void SwFlyFrmAttrMgr::SetLRSpace( long nLeft, long nRight ) { OSL_ENSURE( LONG_MAX != nLeft && LONG_MAX != nRight, "Welchen Raend setzen?" ); - SvxLRSpaceItem aTmp( (SvxLRSpaceItem&)aSet.Get( RES_LR_SPACE ) ); + SvxLRSpaceItem aTmp( (SvxLRSpaceItem&)m_aSet.Get( RES_LR_SPACE ) ); if( LONG_MAX != nLeft ) aTmp.SetLeft( sal_uInt16(nLeft) ); if( LONG_MAX != nRight ) aTmp.SetRight( sal_uInt16(nRight) ); - aSet.Put( aTmp ); + m_aSet.Put( aTmp ); } void SwFlyFrmAttrMgr::SetULSpace( long nTop, long nBottom ) { OSL_ENSURE(LONG_MAX != nTop && LONG_MAX != nBottom, "Welchen Raend setzen?" ); - SvxULSpaceItem aTmp( (SvxULSpaceItem&)aSet.Get( RES_UL_SPACE ) ); + SvxULSpaceItem aTmp( (SvxULSpaceItem&)m_aSet.Get( RES_UL_SPACE ) ); if( LONG_MAX != nTop ) aTmp.SetUpper( sal_uInt16(nTop) ); if( LONG_MAX != nBottom ) aTmp.SetLower( sal_uInt16(nBottom) ); - aSet.Put( aTmp ); + m_aSet.Put( aTmp ); } void SwFlyFrmAttrMgr::SetPos( const Point& rPoint ) @@ -568,42 +568,42 @@ void SwFlyFrmAttrMgr::SetPos( const Point& rPoint ) aVertOrient.SetPos ( rPoint.Y() ); aVertOrient.SetVertOrient( text::VertOrientation::NONE ); - aSet.Put( aVertOrient ); - aSet.Put( aHoriOrient ); + m_aSet.Put( aVertOrient ); + m_aSet.Put( aHoriOrient ); } void SwFlyFrmAttrMgr::SetHorzOrientation( sal_Int16 eOrient ) { SwFmtHoriOrient aHoriOrient( GetHoriOrient() ); aHoriOrient.SetHoriOrient( eOrient ); - aSet.Put( aHoriOrient ); + m_aSet.Put( aHoriOrient ); } void SwFlyFrmAttrMgr::SetVertOrientation( sal_Int16 eOrient ) { SwFmtVertOrient aVertOrient( GetVertOrient() ); aVertOrient.SetVertOrient( eOrient ); - aSet.Put( aVertOrient ); + m_aSet.Put( aVertOrient ); } void SwFlyFrmAttrMgr::SetHeightSizeType( SwFrmSize eType ) { SwFmtFrmSize aSize( GetFrmSize() ); aSize.SetHeightSizeType( eType ); - aSet.Put( aSize ); + m_aSet.Put( aSize ); } void SwFlyFrmAttrMgr::SetSize( const Size& rSize ) { SwFmtFrmSize aSize( GetFrmSize() ); aSize.SetSize(Size(std::max(rSize.Width(), long(MINFLY)), std::max(rSize.Height(), long(MINFLY)))); - aSet.Put( aSize ); + m_aSet.Put( aSize ); } void SwFlyFrmAttrMgr::SetAttrSet(const SfxItemSet& rSet) { - aSet.ClearItem(); - aSet.Put( rSet ); + m_aSet.ClearItem(); + m_aSet.Put( rSet ); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/source/ui/inc/frmmgr.hxx b/sw/source/ui/inc/frmmgr.hxx index 47ea8b39ddc6..8ff94053f2eb 100644 --- a/sw/source/ui/inc/frmmgr.hxx +++ b/sw/source/ui/inc/frmmgr.hxx @@ -49,15 +49,15 @@ const SwTwips DFLT_HEIGHT = MM50; class SW_DLLPUBLIC SwFlyFrmAttrMgr { - SfxItemSet aSet; - Point aAbsPos; - SwWrtShell *pOwnSh; + SfxItemSet m_aSet; + Point m_aAbsPos; + SwWrtShell* m_pOwnSh; - sal_Bool bAbsPos, - bNewFrm; - sal_Bool bIsInVertical; + sal_Bool m_bAbsPos, + m_bNewFrm; + sal_Bool m_bIsInVertical; // --> OD 2009-09-01 #mongolianlayout# - sal_Bool bIsInVerticalL2R; + sal_Bool m_bIsInVerticalL2R; // internal calculation for borders SAL_DLLPRIVATE SwTwips CalcTopSpace(); @@ -73,7 +73,7 @@ public: //CopyCtor for dialogs to check the metrics SwFlyFrmAttrMgr( sal_Bool bNew, SwWrtShell *pSh, const SfxItemSet &rSet ); - inline SwWrtShell* GetShell() { return pOwnSh; } + inline SwWrtShell* GetShell() { return m_pOwnSh; } void SetAnchor(RndStdIds eId); inline RndStdIds GetAnchor() const; @@ -123,8 +123,8 @@ public: void DelAttr(sal_uInt16 nId); // reach out the set - inline const SfxItemSet &GetAttrSet() const { return aSet; } - inline SfxItemSet &GetAttrSet() { return aSet; } + inline const SfxItemSet &GetAttrSet() const { return m_aSet; } + inline SfxItemSet &GetAttrSet() { return m_aSet; } void SetAttrSet(const SfxItemSet& rSet); inline const SwFmtVertOrient &GetVertOrient() const; @@ -140,32 +140,32 @@ public: inline const Size& SwFlyFrmAttrMgr::GetSize() const { - return ((SwFmtFrmSize&)aSet.Get(RES_FRM_SIZE)).GetSize(); + return ((SwFmtFrmSize&)m_aSet.Get(RES_FRM_SIZE)).GetSize(); } inline const SwFmtVertOrient &SwFlyFrmAttrMgr::GetVertOrient() const { - return ((SwFmtVertOrient&)aSet.Get(RES_VERT_ORIENT)); + return ((SwFmtVertOrient&)m_aSet.Get(RES_VERT_ORIENT)); } inline const SwFmtHoriOrient &SwFlyFrmAttrMgr::GetHoriOrient() const { - return ((SwFmtHoriOrient &)aSet.Get(RES_HORI_ORIENT)); + return ((SwFmtHoriOrient &)m_aSet.Get(RES_HORI_ORIENT)); } inline const SwFmtFrmSize& SwFlyFrmAttrMgr::GetFrmSize() const { - return ((SwFmtFrmSize&)aSet.Get(RES_FRM_SIZE)); + return ((SwFmtFrmSize&)m_aSet.Get(RES_FRM_SIZE)); } inline const SvxShadowItem &SwFlyFrmAttrMgr::GetShadow() const { - return ((SvxShadowItem&)aSet.Get(RES_SHADOW)); + return ((SvxShadowItem&)m_aSet.Get(RES_SHADOW)); } inline const SvxBoxItem &SwFlyFrmAttrMgr::GetBox() const { - return ((SvxBoxItem&)aSet.Get(RES_BOX)); + return ((SvxBoxItem&)m_aSet.Get(RES_BOX)); } inline const SwFmtSurround &SwFlyFrmAttrMgr::GetSurround() const { - return ((SwFmtSurround&)aSet.Get(RES_SURROUND)); + return ((SwFmtSurround&)m_aSet.Get(RES_SURROUND)); } inline Point SwFlyFrmAttrMgr::GetPos() const @@ -175,7 +175,7 @@ inline Point SwFlyFrmAttrMgr::GetPos() const inline RndStdIds SwFlyFrmAttrMgr::GetAnchor() const { - return ((SwFmtAnchor&)aSet.Get(RES_ANCHOR)).GetAnchorId(); + return ((SwFmtAnchor&)m_aSet.Get(RES_ANCHOR)).GetAnchorId(); } inline sal_uInt16 SwFlyFrmAttrMgr::GetHeightPercent() const |