diff options
-rw-r--r-- | sw/inc/redline.hxx | 32 | ||||
-rw-r--r-- | sw/source/core/doc/docredln.cxx | 136 | ||||
-rw-r--r-- | sw/source/core/inc/swfntcch.hxx | 12 | ||||
-rw-r--r-- | sw/source/core/txtnode/swfntcch.cxx | 10 |
4 files changed, 95 insertions, 95 deletions
diff --git a/sw/inc/redline.hxx b/sw/inc/redline.hxx index c1bf083be93f..3540a6d36be0 100644 --- a/sw/inc/redline.hxx +++ b/sw/inc/redline.hxx @@ -172,10 +172,10 @@ public: class SW_DLLPUBLIC SwRangeRedline : public SwPaM { - SwRedlineData* pRedlineData; - SwNodeIndex* pContentSect; - bool bDelLastPara : 1; - bool bIsVisible : 1; + SwRedlineData* m_pRedlineData; + SwNodeIndex* m_pContentSect; + bool m_bDelLastPara : 1; + bool m_bIsVisible : 1; sal_uInt32 m_nId; boost::optional<long> m_oLOKLastNodeTop; @@ -194,19 +194,19 @@ public: // For sw3io: pData is taken over! SwRangeRedline(SwRedlineData* pData, const SwPosition& rPos, bool bDelLP) : - SwPaM( rPos ), pRedlineData( pData ), pContentSect( nullptr ), - bDelLastPara( bDelLP ), bIsVisible( true ), m_nId( m_nLastId++ ) + SwPaM( rPos ), m_pRedlineData( pData ), m_pContentSect( nullptr ), + m_bDelLastPara( bDelLP ), m_bIsVisible( true ), m_nId( m_nLastId++ ) {} SwRangeRedline( const SwRangeRedline& ); virtual ~SwRangeRedline() override; sal_uInt32 GetId() const { return m_nId; } - SwNodeIndex* GetContentIdx() const { return pContentSect; } + SwNodeIndex* GetContentIdx() const { return m_pContentSect; } // For Undo. void SetContentIdx( const SwNodeIndex* ); - bool IsVisible() const { return bIsVisible; } - bool IsDelLastPara() const { return bDelLastPara; } + bool IsVisible() const { return m_bIsVisible; } + bool IsDelLastPara() const { return m_bDelLastPara; } void SetStart( const SwPosition& rPos, SwPosition* pSttPtr = nullptr ); void SetEnd( const SwPosition& rPos, SwPosition* pEndPtr = nullptr ); @@ -216,8 +216,8 @@ public: const SwRedlineData& GetRedlineData(sal_uInt16 nPos = 0) const; bool operator!=( const SwRedlineData& rCmp ) const - { return *pRedlineData != rCmp; } - void SetAutoFormatFlag() { pRedlineData->SetAutoFormatFlag(); } + { return *m_pRedlineData != rCmp; } + void SetAutoFormatFlag() { m_pRedlineData->SetAutoFormatFlag(); } sal_uInt16 GetStackCount() const; std::size_t GetAuthor( sal_uInt16 nPos = 0) const; @@ -228,20 +228,20 @@ public: { return static_cast<RedlineType_t>(GetRealType( nPos ) & nsRedlineType_t::REDLINE_NO_FLAG_MASK); } const OUString& GetComment( sal_uInt16 nPos = 0 ) const; - void SetComment( const OUString& rS ) { pRedlineData->SetComment( rS ); } + void SetComment( const OUString& rS ) { m_pRedlineData->SetComment( rS ); } /** ExtraData gets copied, the pointer is therefore not taken over by * the RedLineObject.*/ void SetExtraData( const SwRedlineExtraData* pData ) - { pRedlineData->SetExtraData( pData ); } + { m_pRedlineData->SetExtraData( pData ); } const SwRedlineExtraData* GetExtraData() const - { return pRedlineData->GetExtraData(); } + { return m_pRedlineData->GetExtraData(); } // For UI-side pooling of Redline-actions. // At the moment only used for Autoformat with Redline. // Value != 0 means there can be others! - sal_uInt16 GetSeqNo() const { return pRedlineData->GetSeqNo(); } - void SetSeqNo( sal_uInt16 nNo ) { pRedlineData->SetSeqNo( nNo ); } + sal_uInt16 GetSeqNo() const { return m_pRedlineData->GetSeqNo(); } + void SetSeqNo( sal_uInt16 nNo ) { m_pRedlineData->SetSeqNo( nNo ); } // At Hide/ShowOriginal the list is traversed two times in order to // hide the Del-Redlines via Copy and Delete. diff --git a/sw/source/core/doc/docredln.cxx b/sw/source/core/doc/docredln.cxx index bb1a5a9029c6..1bde85fda73c 100644 --- a/sw/source/core/doc/docredln.cxx +++ b/sw/source/core/doc/docredln.cxx @@ -1011,60 +1011,60 @@ sal_uInt32 SwRangeRedline::m_nLastId = 1; SwRangeRedline::SwRangeRedline(RedlineType_t eTyp, const SwPaM& rPam ) : SwPaM( *rPam.GetMark(), *rPam.GetPoint() ), - pRedlineData( new SwRedlineData( eTyp, GetDoc()->getIDocumentRedlineAccess().GetRedlineAuthor() ) ), - pContentSect( nullptr ), + m_pRedlineData( new SwRedlineData( eTyp, GetDoc()->getIDocumentRedlineAccess().GetRedlineAuthor() ) ), + m_pContentSect( nullptr ), m_nId( m_nLastId++ ) { - bDelLastPara = false; - bIsVisible = true; + m_bDelLastPara = false; + m_bIsVisible = true; if( !rPam.HasMark() ) DeleteMark(); } SwRangeRedline::SwRangeRedline( const SwRedlineData& rData, const SwPaM& rPam ) : SwPaM( *rPam.GetMark(), *rPam.GetPoint() ), - pRedlineData( new SwRedlineData( rData )), - pContentSect( nullptr ), + m_pRedlineData( new SwRedlineData( rData )), + m_pContentSect( nullptr ), m_nId( m_nLastId++ ) { - bDelLastPara = false; - bIsVisible = true; + m_bDelLastPara = false; + m_bIsVisible = true; if( !rPam.HasMark() ) DeleteMark(); } SwRangeRedline::SwRangeRedline( const SwRedlineData& rData, const SwPosition& rPos ) : SwPaM( rPos ), - pRedlineData( new SwRedlineData( rData )), - pContentSect( nullptr ), + m_pRedlineData( new SwRedlineData( rData )), + m_pContentSect( nullptr ), m_nId( m_nLastId++ ) { - bDelLastPara = false; - bIsVisible = true; + m_bDelLastPara = false; + m_bIsVisible = true; } SwRangeRedline::SwRangeRedline( const SwRangeRedline& rCpy ) : SwPaM( *rCpy.GetMark(), *rCpy.GetPoint() ), - pRedlineData( new SwRedlineData( *rCpy.pRedlineData )), - pContentSect( nullptr ), + m_pRedlineData( new SwRedlineData( *rCpy.m_pRedlineData )), + m_pContentSect( nullptr ), m_nId( rCpy.m_nId ) { - bDelLastPara = false; - bIsVisible = true; + m_bDelLastPara = false; + m_bIsVisible = true; if( !rCpy.HasMark() ) DeleteMark(); } SwRangeRedline::~SwRangeRedline() { - if( pContentSect ) + if( m_pContentSect ) { // delete the ContentSection if( !GetDoc()->IsInDtor() ) - GetDoc()->getIDocumentContentOperations().DeleteSection( &pContentSect->GetNode() ); - delete pContentSect; + GetDoc()->getIDocumentContentOperations().DeleteSection( &m_pContentSect->GetNode() ); + delete m_pContentSect; } - delete pRedlineData; + delete m_pRedlineData; } void MaybeNotifyRedlineModification(SwRangeRedline* pRedline, SwDoc* pDoc) @@ -1150,12 +1150,12 @@ void SwRangeRedline::Show(sal_uInt16 nLoop, size_t nMyPos) switch( GetType() ) { case nsRedlineType_t::REDLINE_INSERT: // Content has been inserted - bIsVisible = true; + m_bIsVisible = true; MoveFromSection(nMyPos); break; case nsRedlineType_t::REDLINE_DELETE: // Content has been deleted - bIsVisible = true; + m_bIsVisible = true; MoveFromSection(nMyPos); break; @@ -1180,13 +1180,13 @@ void SwRangeRedline::Hide(sal_uInt16 nLoop, size_t nMyPos) switch( GetType() ) { case nsRedlineType_t::REDLINE_INSERT: // Content has been inserted - bIsVisible = true; + m_bIsVisible = true; if( 1 <= nLoop ) MoveFromSection(nMyPos); break; case nsRedlineType_t::REDLINE_DELETE: // Content has been deleted - bIsVisible = false; + m_bIsVisible = false; switch( nLoop ) { case 0: MoveToSection(); break; @@ -1216,13 +1216,13 @@ void SwRangeRedline::ShowOriginal(sal_uInt16 nLoop, size_t nMyPos) ::sw::UndoGuard const undoGuard(pDoc->GetIDocumentUndoRedo()); // Determine the Type, it's the first on Stack - for( pCur = pRedlineData; pCur->pNext; ) + for( pCur = m_pRedlineData; pCur->pNext; ) pCur = pCur->pNext; switch( pCur->eType ) { case nsRedlineType_t::REDLINE_INSERT: // Content has been inserted - bIsVisible = false; + m_bIsVisible = false; switch( nLoop ) { case 0: MoveToSection(); break; @@ -1232,7 +1232,7 @@ void SwRangeRedline::ShowOriginal(sal_uInt16 nLoop, size_t nMyPos) break; case nsRedlineType_t::REDLINE_DELETE: // Content has been deleted - bIsVisible = true; + m_bIsVisible = true; if( 1 <= nLoop ) MoveFromSection(nMyPos); break; @@ -1319,7 +1319,7 @@ void SwRangeRedline::CalcStartEnd( sal_uLong nNdIdx, sal_Int32& rStart, sal_Int3 void SwRangeRedline::MoveToSection() { - if( !pContentSect ) + if( !m_pContentSect ) { const SwPosition* pStt = Start(), * pEnd = pStt == GetPoint() ? GetMark() : GetPoint(); @@ -1364,7 +1364,7 @@ void SwRangeRedline::MoveToSection() else { if( pCSttNd && !pCEndNd ) - bDelLastPara = true; + m_bDelLastPara = true; pDoc->getIDocumentContentOperations().MoveRange( aPam, aPos, SwMoveFlags::DEFAULT ); } @@ -1377,7 +1377,7 @@ void SwRangeRedline::MoveToSection() pDoc->getIDocumentContentOperations().MoveRange( aPam, aPos, SwMoveFlags::DEFAULT ); } - pContentSect = new SwNodeIndex( *pSttNd ); + m_pContentSect = new SwNodeIndex( *pSttNd ); if( pStt == GetPoint() ) Exchange(); @@ -1390,7 +1390,7 @@ void SwRangeRedline::MoveToSection() void SwRangeRedline::CopyToSection() { - if( pContentSect ) + if( m_pContentSect ) return; const SwPosition* pStt = Start(), @@ -1458,7 +1458,7 @@ void SwRangeRedline::CopyToSection() pDoc->GetDocumentContentOperationsManager().CopyWithFlyInFly( aRg, 0, aInsPos ); } } - pContentSect = new SwNodeIndex( *pSttNd ); + m_pContentSect = new SwNodeIndex( *pSttNd ); pDoc->SetCopyIsMove( bSaveCopyFlag ); pDoc->getIDocumentRedlineAccess().SetRedlineMove( bSaveRdlMoveFlg ); @@ -1467,7 +1467,7 @@ void SwRangeRedline::CopyToSection() void SwRangeRedline::DelCopyOfSection(size_t nMyPos) { - if( pContentSect ) + if( m_pContentSect ) { const SwPosition* pStt = Start(), * pEnd = pStt == GetPoint() ? GetMark() : GetPoint(); @@ -1499,10 +1499,10 @@ void SwRangeRedline::DelCopyOfSection(size_t nMyPos) else if( pCSttNd || pCEndNd ) { if( pCSttNd && !pCEndNd ) - bDelLastPara = true; + m_bDelLastPara = true; pDoc->getIDocumentContentOperations().DeleteRange( aPam ); - if( bDelLastPara ) + if( m_bDelLastPara ) { // To prevent dangling references to the paragraph to // be deleted, redline that point into this paragraph should be @@ -1552,7 +1552,7 @@ void SwRangeRedline::DelCopyOfSection(size_t nMyPos) void SwRangeRedline::MoveFromSection(size_t nMyPos) { - if( pContentSect ) + if( m_pContentSect ) { SwDoc* pDoc = GetDoc(); const SwRedlineTable& rTable = pDoc->getIDocumentRedlineAccess().GetRedlineTable(); @@ -1594,11 +1594,11 @@ void SwRangeRedline::MoveFromSection(size_t nMyPos) } } - const SwNode* pKeptContentSectNode( &pContentSect->GetNode() ); // #i95711# + const SwNode* pKeptContentSectNode( &m_pContentSect->GetNode() ); // #i95711# { - SwPaM aPam( pContentSect->GetNode(), - *pContentSect->GetNode().EndOfSectionNode(), 1, - ( bDelLastPara ? -2 : -1 ) ); + SwPaM aPam( m_pContentSect->GetNode(), + *m_pContentSect->GetNode().EndOfSectionNode(), 1, + ( m_bDelLastPara ? -2 : -1 ) ); SwContentNode* pCNd = aPam.GetContentNode(); if( pCNd ) aPam.GetPoint()->nContent.Assign( pCNd, pCNd->Len() ); @@ -1613,7 +1613,7 @@ void SwRangeRedline::MoveFromSection(size_t nMyPos) const sal_Int32 nPos = GetPoint()->nContent.GetIndex(); SwPosition aPos( *GetPoint() ); - if( bDelLastPara && *aPam.GetPoint() == *aPam.GetMark() ) + if( m_bDelLastPara && *aPam.GetPoint() == *aPam.GetMark() ) { --aPos.nNode; @@ -1631,11 +1631,11 @@ void SwRangeRedline::MoveFromSection(size_t nMyPos) pCNd = GetMark()->nNode.GetNode().GetContentNode(); GetMark()->nContent.Assign( pCNd, nPos ); - if( bDelLastPara ) + if( m_bDelLastPara ) { ++GetPoint()->nNode; GetPoint()->nContent.Assign( pCNd = GetContentNode(), 0 ); - bDelLastPara = false; + m_bDelLastPara = false; } else if( pColl ) pCNd = GetContentNode(); @@ -1652,12 +1652,12 @@ void SwRangeRedline::MoveFromSection(size_t nMyPos) // by comparing it with the "indexed" <SwNode> instance copied before // perform the intrinsic move. // Note: Such condition is e.g. a "delete" change tracking only containing a table. - if ( &pContentSect->GetNode() == pKeptContentSectNode ) + if ( &m_pContentSect->GetNode() == pKeptContentSectNode ) { - pDoc->getIDocumentContentOperations().DeleteSection( &pContentSect->GetNode() ); + pDoc->getIDocumentContentOperations().DeleteSection( &m_pContentSect->GetNode() ); } - delete pContentSect; - pContentSect = nullptr; + delete m_pContentSect; + m_pContentSect = nullptr; // adjustment of redline table positions must take start and // end into account, not point and mark. @@ -1673,16 +1673,16 @@ void SwRangeRedline::MoveFromSection(size_t nMyPos) // for Undo void SwRangeRedline::SetContentIdx( const SwNodeIndex* pIdx ) { - if( pIdx && !pContentSect ) + if( pIdx && !m_pContentSect ) { - pContentSect = new SwNodeIndex( *pIdx ); - bIsVisible = false; + m_pContentSect = new SwNodeIndex( *pIdx ); + m_bIsVisible = false; } - else if( !pIdx && pContentSect ) + else if( !pIdx && m_pContentSect ) { - delete pContentSect; - pContentSect = nullptr; - bIsVisible = false; + delete m_pContentSect; + m_pContentSect = nullptr; + m_bIsVisible = false; } else { @@ -1693,30 +1693,30 @@ void SwRangeRedline::SetContentIdx( const SwNodeIndex* pIdx ) bool SwRangeRedline::CanCombine( const SwRangeRedline& rRedl ) const { return IsVisible() && rRedl.IsVisible() && - pRedlineData->CanCombine( *rRedl.pRedlineData ); + m_pRedlineData->CanCombine( *rRedl.m_pRedlineData ); } void SwRangeRedline::PushData( const SwRangeRedline& rRedl, bool bOwnAsNext ) { - SwRedlineData* pNew = new SwRedlineData( *rRedl.pRedlineData, false ); + SwRedlineData* pNew = new SwRedlineData( *rRedl.m_pRedlineData, false ); if( bOwnAsNext ) { - pNew->pNext = pRedlineData; - pRedlineData = pNew; + pNew->pNext = m_pRedlineData; + m_pRedlineData = pNew; } else { - pNew->pNext = pRedlineData->pNext; - pRedlineData->pNext = pNew; + pNew->pNext = m_pRedlineData->pNext; + m_pRedlineData->pNext = pNew; } } bool SwRangeRedline::PopData() { - if( !pRedlineData->pNext ) + if( !m_pRedlineData->pNext ) return false; - SwRedlineData* pCur = pRedlineData; - pRedlineData = pCur->pNext; + SwRedlineData* pCur = m_pRedlineData; + m_pRedlineData = pCur->pNext; pCur->pNext = nullptr; delete pCur; return true; @@ -1725,7 +1725,7 @@ bool SwRangeRedline::PopData() sal_uInt16 SwRangeRedline::GetStackCount() const { sal_uInt16 nRet = 1; - for( SwRedlineData* pCur = pRedlineData; pCur->pNext; pCur = pCur->pNext ) + for( SwRedlineData* pCur = m_pRedlineData; pCur->pNext; pCur = pCur->pNext ) ++nRet; return nRet; } @@ -1765,7 +1765,7 @@ bool SwRangeRedline::operator<( const SwRangeRedline& rCmp ) const const SwRedlineData & SwRangeRedline::GetRedlineData(const sal_uInt16 nPos) const { - SwRedlineData * pCur = pRedlineData; + SwRedlineData * pCur = m_pRedlineData; sal_uInt16 nP = nPos; @@ -1790,14 +1790,14 @@ OUString SwRangeRedline::GetDescr() bool bDeletePaM = false; // if this redline is visible the content is in this PaM - if (nullptr == pContentSect) + if (nullptr == m_pContentSect) { pPaM = this; } else // otherwise it is saved in pContentSect { - SwNodeIndex aTmpIdx( *pContentSect->GetNode().EndOfSectionNode() ); - pPaM = new SwPaM(*pContentSect, aTmpIdx ); + SwNodeIndex aTmpIdx( *m_pContentSect->GetNode().EndOfSectionNode() ); + pPaM = new SwPaM(*m_pContentSect, aTmpIdx ); bDeletePaM = true; } diff --git a/sw/source/core/inc/swfntcch.hxx b/sw/source/core/inc/swfntcch.hxx index 244291e4c555..29576a95c026 100644 --- a/sw/source/core/inc/swfntcch.hxx +++ b/sw/source/core/inc/swfntcch.hxx @@ -49,8 +49,8 @@ class SwFontObj : public SwCacheObj friend class SwFontAccess; private: - SwFont aSwFont; - const SfxPoolItem* pDefaultArray[ NUM_DEFAULT_VALUES ]; + SwFont m_aSwFont; + const SfxPoolItem* m_pDefaultArray[ NUM_DEFAULT_VALUES ]; public: DECL_FIXEDMEMPOOL_NEWDEL(SwFontObj) @@ -59,14 +59,14 @@ public: virtual ~SwFontObj() override; - SwFont& GetFont() { return aSwFont; } - const SwFont& GetFont() const { return aSwFont; } - const SfxPoolItem** GetDefault() { return pDefaultArray; } + SwFont& GetFont() { return m_aSwFont; } + const SwFont& GetFont() const { return m_aSwFont; } + const SfxPoolItem** GetDefault() { return m_pDefaultArray; } }; class SwFontAccess : public SwCacheAccess { - SwViewShell *pShell; + SwViewShell *m_pShell; protected: virtual SwCacheObj *NewObj( ) override; diff --git a/sw/source/core/txtnode/swfntcch.cxx b/sw/source/core/txtnode/swfntcch.cxx index 8f199191ae4d..3be4d0cc55ab 100644 --- a/sw/source/core/txtnode/swfntcch.cxx +++ b/sw/source/core/txtnode/swfntcch.cxx @@ -34,12 +34,12 @@ SwFontCache *pSwFontCache = nullptr; SwFontObj::SwFontObj( const void *pOwn, SwViewShell *pSh ) : SwCacheObj( pOwn ), - aSwFont( &static_cast<SwTextFormatColl const *>(pOwn)->GetAttrSet(), pSh ? &pSh->getIDocumentSettingAccess() : nullptr ) + m_aSwFont( &static_cast<SwTextFormatColl const *>(pOwn)->GetAttrSet(), pSh ? &pSh->getIDocumentSettingAccess() : nullptr ) { - aSwFont.GoMagic( pSh, aSwFont.GetActual() ); + m_aSwFont.GoMagic( pSh, m_aSwFont.GetActual() ); const SwAttrSet& rAttrSet = static_cast<SwTextFormatColl const *>(pOwn)->GetAttrSet(); for (sal_uInt16 i = RES_CHRATR_BEGIN; i < RES_CHRATR_END; i++) - pDefaultArray[ StackPos[ i ] ] = &rAttrSet.Get( i ); + m_pDefaultArray[ StackPos[ i ] ] = &rAttrSet.Get( i ); } SwFontObj::~SwFontObj() @@ -49,7 +49,7 @@ SwFontObj::~SwFontObj() SwFontAccess::SwFontAccess( const void *pOwn, SwViewShell *pSh ) : SwCacheAccess( *pSwFontCache, pOwn, static_cast<const SwTextFormatColl*>(pOwn)->IsInSwFntCache() ), - pShell( pSh ) + m_pShell( pSh ) { } @@ -61,7 +61,7 @@ SwFontObj *SwFontAccess::Get( ) SwCacheObj *SwFontAccess::NewObj( ) { const_cast<SwTextFormatColl*>(static_cast<const SwTextFormatColl*>(m_pOwner))->SetInSwFntCache( true ); - return new SwFontObj( m_pOwner, pShell ); + return new SwFontObj( m_pOwner, m_pShell ); } SAL_DLLPUBLIC_EXPORT void FlushFontCache() |