sw/inc/swtable.hxx | 60 ++++----- sw/inc/unostyle.hxx | 38 ++--- sw/source/core/doc/tblrwcl.cxx | 94 +++++++------- sw/source/core/fields/ddetbl.cxx | 14 +- sw/source/core/table/swnewtable.cxx | 64 ++++----- sw/source/core/table/swtable.cxx | 60 ++++----- sw/source/core/unocore/unostyle.cxx | 232 ++++++++++++++++++------------------ 7 files changed, 281 insertions(+), 281 deletions(-)
New commits: commit 90cbb22f3fdb1302fac6a707adb9741508aa2f55 Author: Miklos Vajna <vmik...@collabora.co.uk> Date: Mon Oct 19 09:17:09 2015 +0200 sw: prefix members of SwTable Change-Id: Ie2aaa35047c9c11d5030d8ba83f87061e82f5d3a diff --git a/sw/inc/swtable.hxx b/sw/inc/swtable.hxx index 86ebd8c..bf492dd 100644 --- a/sw/inc/swtable.hxx +++ b/sw/inc/swtable.hxx @@ -94,36 +94,36 @@ class SW_DLLPUBLIC SwTable: public SwClient //Client of FrameFormat. { protected: - SwTableLines aLines; + SwTableLines m_aLines; SwTableSortBoxes m_TabSortContentBoxes; - tools::SvRef<SwServerObject> refObj; // In case DataServer -> pointer is set. + tools::SvRef<SwServerObject> m_xRefObj; // In case DataServer -> pointer is set. - SwHTMLTableLayout *pHTMLLayout; + SwHTMLTableLayout *m_pHTMLLayout; // Usually, the table node of a SwTable can be accessed by getting a box // out of m_TabSortContentBoxes, which know their SwStartNode. But in some rare // cases, we need to know the table node of a SwTable, before the table // boxes have been build (SwTableNode::MakeCopy with tables in tables). - SwTableNode* pTableNode; + SwTableNode* m_pTableNode; // Should that be adjustable for every table? - TableChgMode eTableChgMode; + TableChgMode m_eTableChgMode; - sal_uInt16 nGrfsThatResize; // Count of Grfs that initiate a resize of table + sal_uInt16 m_nGraphicsThatResize; // Count of Grfs that initiate a resize of table // at HTML-import. - sal_uInt16 nRowsToRepeat; // Number of rows to repeat on every page. + sal_uInt16 m_nRowsToRepeat; // Number of rows to repeat on every page. /// Name of the table style to be applied on this table. OUString maTableStyleName; - bool bModifyLocked :1; - bool bNewModel :1; // false: old SubTableModel; true: new RowSpanModel + bool m_bModifyLocked :1; + bool m_bNewModel :1; // false: old SubTableModel; true: new RowSpanModel #ifdef DBG_UTIL /// This is set by functions (like Merge()) to forbid a late model change. bool m_bDontChangeModel; #endif - bool IsModifyLocked(){ return bModifyLocked;} + bool IsModifyLocked(){ return m_bModifyLocked;} virtual void Modify( const SfxPoolItem* pOld, const SfxPoolItem* pNew ) override; @@ -164,18 +164,18 @@ private: public: - SwHTMLTableLayout *GetHTMLTableLayout() { return pHTMLLayout; } - const SwHTMLTableLayout *GetHTMLTableLayout() const { return pHTMLLayout; } + SwHTMLTableLayout *GetHTMLTableLayout() { return m_pHTMLLayout; } + const SwHTMLTableLayout *GetHTMLTableLayout() const { return m_pHTMLLayout; } void SetHTMLTableLayout( SwHTMLTableLayout *p ); //Change of property! - sal_uInt16 IncGrfsThatResize() { return ++nGrfsThatResize; } - sal_uInt16 DecGrfsThatResize() { return nGrfsThatResize ? --nGrfsThatResize : 0; } + sal_uInt16 IncGrfsThatResize() { return ++m_nGraphicsThatResize; } + sal_uInt16 DecGrfsThatResize() { return m_nGraphicsThatResize ? --m_nGraphicsThatResize : 0; } - void LockModify() { bModifyLocked = true; } // Must be used always - void UnlockModify() { bModifyLocked = false;} // in pairs! + void LockModify() { m_bModifyLocked = true; } // Must be used always + void UnlockModify() { m_bModifyLocked = false;} // in pairs! - void SetTableModel( bool bNew ){ bNewModel = bNew; } - bool IsNewModel() const { return bNewModel; } + void SetTableModel( bool bNew ){ m_bNewModel = bNew; } + bool IsNewModel() const { return m_bNewModel; } /// Return the table style name of this table. OUString GetTableStyleName() const { return maTableStyleName; } @@ -183,14 +183,14 @@ public: /// Set the new table style name for this table. void SetTableStyleName(const OUString& rName) { maTableStyleName = rName; } - sal_uInt16 GetRowsToRepeat() const { return std::min( (sal_uInt16)GetTabLines().size(), nRowsToRepeat ); } - sal_uInt16 _GetRowsToRepeat() const { return nRowsToRepeat; } - void SetRowsToRepeat( sal_uInt16 nNumOfRows ) { nRowsToRepeat = nNumOfRows; } + sal_uInt16 GetRowsToRepeat() const { return std::min( (sal_uInt16)GetTabLines().size(), m_nRowsToRepeat ); } + sal_uInt16 _GetRowsToRepeat() const { return m_nRowsToRepeat; } + void SetRowsToRepeat( sal_uInt16 nNumOfRows ) { m_nRowsToRepeat = nNumOfRows; } bool IsHeadline( const SwTableLine& rLine ) const; - SwTableLines &GetTabLines() { return aLines; } - const SwTableLines &GetTabLines() const { return aLines; } + SwTableLines &GetTabLines() { return m_aLines; } + const SwTableLines &GetTabLines() const { return m_aLines; } SwTableFormat* GetFrameFormat() { return static_cast<SwTableFormat*>(GetRegisteredIn()); } SwTableFormat* GetFrameFormat() const { return const_cast<SwTableFormat*>(static_cast<const SwTableFormat*>(GetRegisteredIn())); } @@ -226,7 +226,7 @@ public: #ifdef DBG_UTIL m_bDontChangeModel = true; #endif - return bNewModel ? NewMerge( pDoc, rBoxes, rMerged, pMergeBox, pUndo ) : + return m_bNewModel ? NewMerge( pDoc, rBoxes, rMerged, pMergeBox, pUndo ) : OldMerge( pDoc, rBoxes, pMergeBox, pUndo ); } bool SplitRow( SwDoc* pDoc, const SwSelBoxes& rBoxes, sal_uInt16 nCnt=1, @@ -235,7 +235,7 @@ public: #ifdef DBG_UTIL m_bDontChangeModel = true; #endif - return bNewModel ? NewSplitRow( pDoc, rBoxes, nCnt, bSameHeight ) : + return m_bNewModel ? NewSplitRow( pDoc, rBoxes, nCnt, bSameHeight ) : OldSplitRow( pDoc, rBoxes, nCnt, bSameHeight ); } bool PrepareMerge( const SwPaM& rPam, SwSelBoxes& rBoxes, @@ -316,18 +316,18 @@ public: // Returns the table node via m_TabSortContentBoxes or pTableNode. SwTableNode* GetTableNode() const; - void SetTableNode( SwTableNode* pNode ) { pTableNode = pNode; } + void SetTableNode( SwTableNode* pNode ) { m_pTableNode = pNode; } // Data server methods. void SetRefObject( SwServerObject* ); - const SwServerObject* GetObject() const { return &refObj; } - SwServerObject* GetObject() { return &refObj; } + const SwServerObject* GetObject() const { return &m_xRefObj; } + SwServerObject* GetObject() { return &m_xRefObj; } // Fill data for chart. void UpdateCharts() const; - TableChgMode GetTableChgMode() const { return eTableChgMode; } - void SetTableChgMode( TableChgMode eMode ) { eTableChgMode = eMode; } + TableChgMode GetTableChgMode() const { return m_eTableChgMode; } + void SetTableChgMode( TableChgMode eMode ) { m_eTableChgMode = eMode; } bool SetColWidth( SwTableBox& rAktBox, sal_uInt16 eType, SwTwips nAbsDiff, SwTwips nRelDiff, SwUndo** ppUndo ); diff --git a/sw/source/core/doc/tblrwcl.cxx b/sw/source/core/doc/tblrwcl.cxx index 6fa089d..8be5172 100644 --- a/sw/source/core/doc/tblrwcl.cxx +++ b/sw/source/core/doc/tblrwcl.cxx @@ -166,8 +166,8 @@ typedef bool (*FN_lcl_SetBoxWidth)(SwTableLine*, CR_SetBoxWidth&, SwTwips, bool #define CHECKBOXWIDTH \ { \ SwTwips nSize = GetFrameFormat()->GetFrmSize().GetWidth(); \ - for (size_t nTmp = 0; nTmp < aLines.size(); ++nTmp) \ - ::_CheckBoxWidth( *aLines[ nTmp ], nSize ); \ + for (size_t nTmp = 0; nTmp < m_aLines.size(); ++nTmp) \ + ::_CheckBoxWidth( *m_aLines[ nTmp ], nSize ); \ } #define CHECKTABLELAYOUT \ @@ -3438,7 +3438,7 @@ bool SwTable::SetColWidth( SwTableBox& rAktBox, sal_uInt16 eType, { case nsTableChgWidthHeightType::WH_COL_RIGHT: case nsTableChgWidthHeightType::WH_COL_LEFT: - if( TBLVAR_CHGABS == eTableChgMode ) + if( TBLVAR_CHGABS == m_eTableChgMode ) { if( bInsDel ) bBigger = !bBigger; @@ -3469,22 +3469,22 @@ bool SwTable::SetColWidth( SwTableBox& rAktBox, sal_uInt16 eType, if( !bRet ) { // Then call itself recursively; only with another mode (proportional) - TableChgMode eOld = eTableChgMode; - eTableChgMode = TBLFIX_CHGPROP; + TableChgMode eOld = m_eTableChgMode; + m_eTableChgMode = TBLFIX_CHGPROP; bRet = SetColWidth( rAktBox, eType, nAbsDiff, nRelDiff, ppUndo ); - eTableChgMode = eOld; + m_eTableChgMode = eOld; return bRet; } } else { bRet = true; - for( n = 0; n < aLines.size(); ++n ) + for( n = 0; n < m_aLines.size(); ++n ) { aParam.LoopClear(); - if( !(*fnSelBox)( aLines[ n ], aParam, nDistStt, true )) + if( !(*fnSelBox)( m_aLines[ n ], aParam, nDistStt, true )) { bRet = false; break; @@ -3526,8 +3526,8 @@ bool SwTable::SetColWidth( SwTableBox& rAktBox, sal_uInt16 eType, // Break down to USHRT_MAX / 2 CR_SetBoxWidth aTmpPara( 0, aSz.GetWidth() / 2, 0, aSz.GetWidth(), aSz.GetWidth(), aParam.pTableNd ); - for( size_t nLn = 0; nLn < aLines.size(); ++nLn ) - ::lcl_AjustLines( aLines[ nLn ], aTmpPara ); + for( size_t nLn = 0; nLn < m_aLines.size(); ++nLn ) + ::lcl_AjustLines( m_aLines[ nLn ], aTmpPara ); aSz.SetWidth( aSz.GetWidth() / 2 ); aParam.nDiff = nRelDiff /= 2; aParam.nSide /= 2; @@ -3588,11 +3588,11 @@ bool SwTable::SetColWidth( SwTableBox& rAktBox, sal_uInt16 eType, UnlockModify(); - for( n = aLines.size(); n; ) + for( n = m_aLines.size(); n; ) { --n; aParam.LoopClear(); - (*fnSelBox)( aLines[ n ], aParam, nDistStt, false ); + (*fnSelBox)( m_aLines[ n ], aParam, nDistStt, false ); } // If the Table happens to contain relative values (USHORT_MAX), @@ -3610,7 +3610,7 @@ bool SwTable::SetColWidth( SwTableBox& rAktBox, sal_uInt16 eType, ( bLeft ? nDist != 0 : std::abs( rSz.GetWidth() - nDist ) > COLFUZZY ) ) { bRet = true; - if( bLeft && TBLFIX_CHGABS == eTableChgMode && !bInsDel ) + if( bLeft && TBLFIX_CHGABS == m_eTableChgMode && !bInsDel ) aParam.bBigger = !bBigger; // First test if we have room at all @@ -3618,10 +3618,10 @@ bool SwTable::SetColWidth( SwTableBox& rAktBox, sal_uInt16 eType, { if( aParam.bBigger ) { - for( n = 0; n < aLines.size(); ++n ) + for( n = 0; n < m_aLines.size(); ++n ) { aParam.LoopClear(); - if( !(*fnSelBox)( aLines[ n ], aParam, nDistStt, true )) + if( !(*fnSelBox)( m_aLines[ n ], aParam, nDistStt, true )) { bRet = false; break; @@ -3633,10 +3633,10 @@ bool SwTable::SetColWidth( SwTableBox& rAktBox, sal_uInt16 eType, if( ( bRet = bLeft ? nDist != 0 : ( rSz.GetWidth() - nDist ) > COLFUZZY ) ) { - for( n = 0; n < aLines.size(); ++n ) + for( n = 0; n < m_aLines.size(); ++n ) { aParam.LoopClear(); - if( !(*fnOtherBox)( aLines[ n ], aParam, 0, true )) + if( !(*fnOtherBox)( m_aLines[ n ], aParam, 0, true )) { bRet = false; break; @@ -3655,10 +3655,10 @@ bool SwTable::SetColWidth( SwTableBox& rAktBox, sal_uInt16 eType, // We also need to test this! bRet = true; - for( n = 0; n < aLines.size(); ++n ) + for( n = 0; n < m_aLines.size(); ++n ) { aParam.LoopClear(); - if( !(*fnSelBox)( aLines[ n ], aParam, nDistStt, true )) + if( !(*fnSelBox)( m_aLines[ n ], aParam, nDistStt, true )) { bRet = false; break; @@ -3669,10 +3669,10 @@ bool SwTable::SetColWidth( SwTableBox& rAktBox, sal_uInt16 eType, } else if( aParam.bBigger ) { - for( n = 0; n < aLines.size(); ++n ) + for( n = 0; n < m_aLines.size(); ++n ) { aParam.LoopClear(); - if( !(*fnOtherBox)( aLines[ n ], aParam, 0, true )) + if( !(*fnOtherBox)( m_aLines[ n ], aParam, 0, true )) { bRet = false; break; @@ -3681,10 +3681,10 @@ bool SwTable::SetColWidth( SwTableBox& rAktBox, sal_uInt16 eType, } else { - for( n = 0; n < aLines.size(); ++n ) + for( n = 0; n < m_aLines.size(); ++n ) { aParam.LoopClear(); - if( !(*fnSelBox)( aLines[ n ], aParam, nDistStt, true )) + if( !(*fnSelBox)( m_aLines[ n ], aParam, nDistStt, true )) { bRet = false; break; @@ -3709,27 +3709,27 @@ bool SwTable::SetColWidth( SwTableBox& rAktBox, sal_uInt16 eType, *ppUndo = new SwUndoAttrTable( *aParam.pTableNd, true ); if( bInsDel - ? ( TBLFIX_CHGABS == eTableChgMode ? (bBigger && bLeft) : bLeft ) - : ( TBLFIX_CHGABS != eTableChgMode && bLeft ) ) + ? ( TBLFIX_CHGABS == m_eTableChgMode ? (bBigger && bLeft) : bLeft ) + : ( TBLFIX_CHGABS != m_eTableChgMode && bLeft ) ) { - for( n = aLines.size(); n; ) + for( n = m_aLines.size(); n; ) { --n; aParam.LoopClear(); aParam1.LoopClear(); - (*fnSelBox)( aLines[ n ], aParam, nDistStt, false ); - (*fnOtherBox)( aLines[ n ], aParam1, nDistStt, false ); + (*fnSelBox)( m_aLines[ n ], aParam, nDistStt, false ); + (*fnOtherBox)( m_aLines[ n ], aParam1, nDistStt, false ); } } else { - for( n = aLines.size(); n; ) + for( n = m_aLines.size(); n; ) { --n; aParam.LoopClear(); aParam1.LoopClear(); - (*fnOtherBox)( aLines[ n ], aParam1, nDistStt, false ); - (*fnSelBox)( aLines[ n ], aParam, nDistStt, false ); + (*fnOtherBox)( m_aLines[ n ], aParam1, nDistStt, false ); + (*fnSelBox)( m_aLines[ n ], aParam, nDistStt, false ); } } } @@ -3738,21 +3738,21 @@ bool SwTable::SetColWidth( SwTableBox& rAktBox, sal_uInt16 eType, case nsTableChgWidthHeightType::WH_CELL_RIGHT: case nsTableChgWidthHeightType::WH_CELL_LEFT: - if( TBLVAR_CHGABS == eTableChgMode ) + if( TBLVAR_CHGABS == m_eTableChgMode ) { // Then call itself recursively; only with another mode (proportional) - TableChgMode eOld = eTableChgMode; - eTableChgMode = TBLFIX_CHGABS; + TableChgMode eOld = m_eTableChgMode; + m_eTableChgMode = TBLFIX_CHGABS; bRet = SetColWidth( rAktBox, eType, nAbsDiff, nRelDiff, ppUndo ); - eTableChgMode = eOld; + m_eTableChgMode = eOld; return bRet; } else if( bInsDel || ( bLeft ? nDist != 0 : (rSz.GetWidth() - nDist) > COLFUZZY )) { - if( bLeft && TBLFIX_CHGABS == eTableChgMode && !bInsDel ) + if( bLeft && TBLFIX_CHGABS == m_eTableChgMode && !bInsDel ) aParam.bBigger = !bBigger; // First, see if there is enough room at all @@ -3824,8 +3824,8 @@ bool SwTable::SetColWidth( SwTableBox& rAktBox, sal_uInt16 eType, *ppUndo = new SwUndoAttrTable( *aParam.pTableNd, true ); if( bInsDel - ? ( TBLFIX_CHGABS == eTableChgMode ? (bBigger && bLeft) : bLeft ) - : ( TBLFIX_CHGABS != eTableChgMode && bLeft ) ) + ? ( TBLFIX_CHGABS == m_eTableChgMode ? (bBigger && bLeft) : bLeft ) + : ( TBLFIX_CHGABS != m_eTableChgMode && bLeft ) ) { (*fnSelBox)( pLine, aParam, nDistStt, false ); (*fnOtherBox)( pLine, aParam1, nDistStt, false ); @@ -3858,7 +3858,7 @@ bool SwTable::SetColWidth( SwTableBox& rAktBox, sal_uInt16 eType, if (ppUndo && *ppUndo && aParam.pUndo) { - aParam.pUndo->SetColWidthParam( nBoxIdx, static_cast<sal_uInt16>(eTableChgMode), eType, + aParam.pUndo->SetColWidthParam( nBoxIdx, static_cast<sal_uInt16>(m_eTableChgMode), eType, nAbsDiff, nRelDiff ); if( !aParam.bBigger ) aParam.pUndo->SaveNewBoxes( *aParam.pTableNd, aTmpLst ); @@ -4147,7 +4147,7 @@ bool SwTable::SetRowHeight( SwTableBox& rAktBox, sal_uInt16 eType, else fnSelLine = lcl_SetSelLineHeight; - SwTableLines* pLines = &aLines; + SwTableLines* pLines = &m_aLines; // How do we get to the height? switch( eType & 0xff ) @@ -4171,7 +4171,7 @@ bool SwTable::SetRowHeight( SwTableBox& rAktBox, sal_uInt16 eType, nAbsDiff = GetRowFrm( *pBaseLine )->Frm().Height(); } - if( TBLVAR_CHGABS == eTableChgMode ) + if( TBLVAR_CHGABS == m_eTableChgMode ) { // First test if we have room at all if( bBigger ) @@ -4223,7 +4223,7 @@ bool SwTable::SetRowHeight( SwTableBox& rAktBox, sal_uInt16 eType, nStt = nBaseLinePos + 1, nEnd = pLines->size(); // Get the current Lines' height - if( TBLFIX_CHGPROP == eTableChgMode ) + if( TBLFIX_CHGPROP == m_eTableChgMode ) { for( auto n = nStt; n < nEnd; ++n ) { @@ -4287,7 +4287,7 @@ bool SwTable::SetRowHeight( SwTableBox& rAktBox, sal_uInt16 eType, *ppUndo = new SwUndoAttrTable( *aParam.pTableNd, true ); CR_SetLineHeight aParam1( aParam ); - if( TBLFIX_CHGPROP == eTableChgMode && !bBigger && + if( TBLFIX_CHGPROP == m_eTableChgMode && !bBigger && !aParam.nMaxSpace ) { // We need to distribute the space evenly among all the Lines. @@ -4315,13 +4315,13 @@ bool SwTable::SetRowHeight( SwTableBox& rAktBox, sal_uInt16 eType, else { // Then call itself recursively; only with another mode (proportional) - TableChgMode eOld = eTableChgMode; - eTableChgMode = TBLVAR_CHGABS; + TableChgMode eOld = m_eTableChgMode; + m_eTableChgMode = TBLVAR_CHGABS; bRet = SetRowHeight( rAktBox, eType, nAbsDiff, nRelDiff, ppUndo ); - eTableChgMode = eOld; + m_eTableChgMode = eOld; xFndBox.reset(); } } @@ -4344,7 +4344,7 @@ bool SwTable::SetRowHeight( SwTableBox& rAktBox, sal_uInt16 eType, if (ppUndo && *ppUndo && aParam.pUndo) { - aParam.pUndo->SetColWidthParam( nBoxIdx, static_cast<sal_uInt16>(eTableChgMode), eType, + aParam.pUndo->SetColWidthParam( nBoxIdx, static_cast<sal_uInt16>(m_eTableChgMode), eType, nAbsDiff, nRelDiff ); if( bBigger ) aParam.pUndo->SaveNewBoxes( *aParam.pTableNd, aTmpLst ); diff --git a/sw/source/core/fields/ddetbl.cxx b/sw/source/core/fields/ddetbl.cxx index 2edec00..e1d674a 100644 --- a/sw/source/core/fields/ddetbl.cxx +++ b/sw/source/core/fields/ddetbl.cxx @@ -44,11 +44,11 @@ SwDDETable::SwDDETable( SwTable& rTable, SwDDEFieldType* pDDEType, bool bUpdate m_TabSortContentBoxes.insert(rTable.GetTabSortBoxes()); rTable.GetTabSortBoxes().clear(); - aLines.insert( aLines.begin(), + m_aLines.insert( m_aLines.begin(), rTable.GetTabLines().begin(), rTable.GetTabLines().end() ); // move lines rTable.GetTabLines().clear(); - if( !aLines.empty() ) + if( !m_aLines.empty() ) { const SwNode& rNd = *GetTabSortBoxes()[0]->GetSttNd(); if( rNd.GetNodes().IsDocNodes() ) @@ -66,7 +66,7 @@ SwDDETable::~SwDDETable() { SwDDEFieldType* pFieldTyp = static_cast<SwDDEFieldType*>(aDepend.GetRegisteredIn()); SwDoc* pDoc = GetFrameFormat()->GetDoc(); - if( !pDoc->IsInDtor() && !aLines.empty() && + if( !pDoc->IsInDtor() && !m_aLines.empty() && GetTabSortBoxes()[0]->GetSttNd()->GetNodes().IsDocNodes() ) pFieldTyp->DecRefCnt(); @@ -100,7 +100,7 @@ void SwDDETable::ChangeContent() OSL_ENSURE( GetFrameFormat(), "No FrameFormat" ); // Is this the correct NodesArray? (because of UNDO) - if( aLines.empty() ) + if( m_aLines.empty() ) return; OSL_ENSURE( !GetTabSortBoxes().empty(), "Table without content?" ); if( !GetTabSortBoxes()[0]->GetSttNd()->GetNodes().IsDocNodes() ) @@ -112,11 +112,11 @@ void SwDDETable::ChangeContent() OUString aExpand = comphelper::string::remove(pDDEType->GetExpansion(), '\r'); sal_Int32 nExpandTokenPos = 0; - for( size_t n = 0; n < aLines.size(); ++n ) + for( size_t n = 0; n < m_aLines.size(); ++n ) { OUString aLine = aExpand.getToken( 0, '\n', nExpandTokenPos ); sal_Int32 nLineTokenPos = 0; - SwTableLine* pLine = aLines[ n ]; + SwTableLine* pLine = m_aLines[ n ]; for( size_t i = 0; i < pLine->GetTabBoxes().size(); ++i ) { SwTableBox* pBox = pLine->GetTabBoxes()[ i ]; @@ -153,7 +153,7 @@ bool SwDDETable::NoDDETable() SwDoc* pDoc = GetFrameFormat()->GetDoc(); // Is this the correct NodesArray? (because of UNDO) - if( aLines.empty() ) + if( m_aLines.empty() ) return false; OSL_ENSURE( !GetTabSortBoxes().empty(), "Table without content?" ); SwNode* pNd = const_cast<SwNode*>(static_cast<SwNode const *>(GetTabSortBoxes()[0]->GetSttNd())); diff --git a/sw/source/core/table/swnewtable.cxx b/sw/source/core/table/swnewtable.cxx index 924546c..c06a42f 100644 --- a/sw/source/core/table/swnewtable.cxx +++ b/sw/source/core/table/swnewtable.cxx @@ -323,22 +323,22 @@ static void lcl_ChangeRowSpan( const SwTable& rTable, const long nDiff, SwBoxSelection* SwTable::CollectBoxSelection( const SwPaM& rPam ) const { - OSL_ENSURE( bNewModel, "Don't call me for old tables" ); - if( aLines.empty() ) + OSL_ENSURE( m_bNewModel, "Don't call me for old tables" ); + if( m_aLines.empty() ) return 0; const SwNode* pStartNd = rPam.Start()->nNode.GetNode().FindTableBoxStartNode(); const SwNode* pEndNd = rPam.End()->nNode.GetNode().FindTableBoxStartNode(); if( !pStartNd || !pEndNd || pStartNd == pEndNd ) return 0; - const size_t nLines = aLines.size(); + const size_t nLines = m_aLines.size(); size_t nTop = 0; size_t nBottom = 0; long nMin = 0, nMax = 0; int nFound = 0; for( size_t nRow = 0; nFound < 2 && nRow < nLines; ++nRow ) { - SwTableLine* pLine = aLines[nRow]; + SwTableLine* pLine = m_aLines[nRow]; OSL_ENSURE( pLine, "Missing table line" ); const size_t nCols = pLine->GetTabBoxes().size(); for( size_t nCol = 0; nCol < nCols; ++nCol ) @@ -378,7 +378,7 @@ SwBoxSelection* SwTable::CollectBoxSelection( const SwPaM& rPam ) const long nRightSpanCnt = 0; for( size_t nRow = nTop; nRow <= nBottom && bOkay && nRow < nLines; ++nRow ) { - SwTableLine* pLine = aLines[nRow]; + SwTableLine* pLine = m_aLines[nRow]; OSL_ENSURE( pLine, "Missing table line" ); SwSelBoxes *pBoxes = new SwSelBoxes(); long nRight = 0; @@ -653,16 +653,16 @@ insertion behind (true) or before (false) the selected boxes bool SwTable::NewInsertCol( SwDoc* pDoc, const SwSelBoxes& rBoxes, sal_uInt16 nCnt, bool bBehind ) { - if( aLines.empty() || !nCnt ) + if( m_aLines.empty() || !nCnt ) return false; CHECK_TABLE( *this ) long nNewBoxWidth = 0; - std::vector< sal_uInt16 > aInsPos( aLines.size(), USHRT_MAX ); + std::vector< sal_uInt16 > aInsPos( m_aLines.size(), USHRT_MAX ); { // Calculation of the insert positions and the width of the new boxes sal_uInt64 nTableWidth = 0; - for( size_t i = 0; i < aLines[0]->GetTabBoxes().size(); ++i ) - nTableWidth += aLines[0]->GetTabBoxes()[i]->GetFrameFormat()->GetFrmSize().GetWidth(); + for( size_t i = 0; i < m_aLines[0]->GetTabBoxes().size(); ++i ) + nTableWidth += m_aLines[0]->GetTabBoxes()[i]->GetFrameFormat()->GetFrmSize().GetWidth(); // Fill the vector of insert positions and the (average) width to insert sal_uInt64 nAddWidth = lcl_InsertPosition( *this, aInsPos, rBoxes, bBehind ); @@ -694,9 +694,9 @@ bool SwTable::NewInsertCol( SwDoc* pDoc, const SwSelBoxes& rBoxes, size_t nLastLine = SAL_MAX_SIZE; long nLastRowSpan = 1; - for( size_t i = 0; i < aLines.size(); ++i ) + for( size_t i = 0; i < m_aLines.size(); ++i ) { - SwTableLine* pLine = aLines[ i ]; + SwTableLine* pLine = m_aLines[ i ]; sal_uInt16 nInsPos = aInsPos[i]; assert(nInsPos != USHRT_MAX); // didn't find insert position SwTableBox* pBox = pLine->GetTabBoxes()[ nInsPos ]; @@ -713,7 +713,7 @@ bool SwTable::NewInsertCol( SwDoc* pDoc, const SwSelBoxes& rBoxes, bNewSpan = true; while( nLastLine < i ) { - SwTableLine* pTmpLine = aLines[ nLastLine ]; + SwTableLine* pTmpLine = m_aLines[ nLastLine ]; sal_uInt16 nTmpPos = aInsPos[nLastLine]; if( bBehind ) ++nTmpPos; @@ -770,7 +770,7 @@ bool SwTable::NewInsertCol( SwDoc* pDoc, const SwSelBoxes& rBoxes, aFndBox.MakeFrms( *this ); #if OSL_DEBUG_LEVEL > 0 { - const SwTableBoxes &rTabBoxes = aLines[0]->GetTabBoxes(); + const SwTableBoxes &rTabBoxes = m_aLines[0]->GetTabBoxes(); long nNewWidth = 0; for( size_t i = 0; i < rTabBoxes.size(); ++i ) nNewWidth += rTabBoxes[i]->GetFrameFormat()->GetFrmSize().GetWidth(); @@ -810,7 +810,7 @@ can be Null, e.g. when called by Redo(..) bool SwTable::PrepareMerge( const SwPaM& rPam, SwSelBoxes& rBoxes, SwSelBoxes& rMerged, SwTableBox** ppMergeBox, SwUndoTableMerge* pUndo ) { - if( !bNewModel ) + if( !m_bNewModel ) { ::GetMergeSel( rPam, rBoxes, ppMergeBox, pUndo ); return rBoxes.size() > 1; @@ -979,7 +979,7 @@ void SwTable::_FindSuperfluousRows( SwSelBoxes& rBoxes, sal_uInt16 nLastLn = GetTabLines().GetPos( pLastLn ); for( sal_uInt16 nRow = nFirstLn; nRow <= nLastLn; ++nRow ) { - SwTableLine* pLine = aLines[nRow]; + SwTableLine* pLine = m_aLines[nRow]; OSL_ENSURE( pLine, "Missing table line" ); const size_t nCols = pLine->GetTabBoxes().size(); bool bSuperfl = true; @@ -1650,8 +1650,8 @@ static void lcl_SearchSelBox( const SwTable &rTable, SwSelBoxes& rBoxes, long nM void SwTable::CreateSelection( const SwPaM& rPam, SwSelBoxes& rBoxes, const SearchType eSearch, bool bChkProtected ) const { - OSL_ENSURE( bNewModel, "Don't call me for old tables" ); - if( aLines.empty() ) + OSL_ENSURE( m_bNewModel, "Don't call me for old tables" ); + if( m_aLines.empty() ) return; const SwNode* pStartNd = rPam.GetPoint()->nNode.GetNode().FindTableBoxStartNode(); const SwNode* pEndNd = rPam.GetMark()->nNode.GetNode().FindTableBoxStartNode(); @@ -1668,7 +1668,7 @@ void SwTable::CreateSelection( const SwNode* pStartNd, const SwNode* pEndNd, { rBoxes.clear(); // Looking for start and end of the selection given by SwNode-pointer - const size_t nLines = aLines.size(); + const size_t nLines = m_aLines.size(); // nTop becomes the line number of the upper box // nBottom becomes the line number of the lower box size_t nTop = 0; @@ -1683,7 +1683,7 @@ void SwTable::CreateSelection( const SwNode* pStartNd, const SwNode* pEndNd, int nFound = 0; for( size_t nRow = 0; nFound < 2 && nRow < nLines; ++nRow ) { - SwTableLine* pLine = aLines[nRow]; + SwTableLine* pLine = m_aLines[nRow]; OSL_ENSURE( pLine, "Missing table line" ); const size_t nCols = pLine->GetTabBoxes().size(); for( size_t nCol = 0; nCol < nCols; ++nCol ) @@ -1728,7 +1728,7 @@ void SwTable::CreateSelection( const SwNode* pStartNd, const SwNode* pEndNd, // with a positive row span will be collected for( size_t nRow = nTop; nRow <= nBottom; ++nRow ) { - SwTableLine* pLine = aLines[nRow]; + SwTableLine* pLine = m_aLines[nRow]; OSL_ENSURE( pLine, "Missing table line" ); const size_t nCount = pLine->GetTabBoxes().size(); for( size_t nCurrBox = 0; nCurrBox < nCount; ++nCurrBox ) @@ -1772,20 +1772,20 @@ void SwTable::CreateSelection( const SwNode* pStartNd, const SwNode* pEndNd, { for( size_t i = 0; i < nTop; ++i ) lcl_SearchSelBox( *this, rBoxes, nUpperMin, nUpperMax, - *aLines[i], bChkProtected, bColumn ); + *m_aLines[i], bChkProtected, bColumn ); } { long nMin = nUpperMin < nLowerMin ? nUpperMin : nLowerMin; long nMax = nUpperMax < nLowerMax ? nLowerMax : nUpperMax; for( size_t i = nTop; i <= nBottom; ++i ) - lcl_SearchSelBox( *this, rBoxes, nMin, nMax, *aLines[i], + lcl_SearchSelBox( *this, rBoxes, nMin, nMax, *m_aLines[i], bChkProtected, bColumn ); } if( bColumn ) { for( size_t i = nBottom + 1; i < nLines; ++i ) - lcl_SearchSelBox( *this, rBoxes, nLowerMin, nLowerMax, *aLines[i], + lcl_SearchSelBox( *this, rBoxes, nLowerMin, nLowerMax, *m_aLines[i], bChkProtected, true ); } } @@ -1796,18 +1796,18 @@ void SwTable::CreateSelection( const SwNode* pStartNd, const SwNode* pEndNd, void SwTable::ExpandColumnSelection( SwSelBoxes& rBoxes, long &rMin, long &rMax ) const { - OSL_ENSURE( bNewModel, "Don't call me for old tables" ); + OSL_ENSURE( m_bNewModel, "Don't call me for old tables" ); rMin = 0; rMax = 0; - if( aLines.empty() || rBoxes.empty() ) + if( m_aLines.empty() || rBoxes.empty() ) return; - const size_t nLineCnt = aLines.size(); + const size_t nLineCnt = m_aLines.size(); const size_t nBoxCnt = rBoxes.size(); size_t nBox = 0; for( size_t nRow = 0; nRow < nLineCnt && nBox < nBoxCnt; ++nRow ) { - SwTableLine* pLine = aLines[nRow]; + SwTableLine* pLine = m_aLines[nRow]; OSL_ENSURE( pLine, "Missing table line" ); const size_t nCols = pLine->GetTabBoxes().size(); for( size_t nCol = 0; nCol < nCols; ++nCol ) @@ -1824,7 +1824,7 @@ void SwTable::ExpandColumnSelection( SwSelBoxes& rBoxes, long &rMin, long &rMax } for( size_t nRow = 0; nRow < nLineCnt; ++nRow ) { - SwTableLine* pLine = aLines[nRow]; + SwTableLine* pLine = m_aLines[nRow]; const size_t nCols = pLine->GetTabBoxes().size(); long nRight = 0; for( size_t nCurrBox = 0; nCurrBox < nCols; ++nCurrBox ) @@ -1843,17 +1843,17 @@ void SwTable::ExpandColumnSelection( SwSelBoxes& rBoxes, long &rMin, long &rMax */ void SwTable::PrepareDeleteCol( long nMin, long nMax ) { - OSL_ENSURE( bNewModel, "Don't call me for old tables" ); - if( aLines.empty() || nMax < nMin ) + OSL_ENSURE( m_bNewModel, "Don't call me for old tables" ); + if( m_aLines.empty() || nMax < nMin ) return; long nMid = nMin ? ( nMin + nMax ) / 2 : 0; const SwTwips nTabSize = GetFrameFormat()->GetFrmSize().GetWidth(); if( nTabSize == nMax ) nMid = nMax; - const size_t nLineCnt = aLines.size(); + const size_t nLineCnt = m_aLines.size(); for( size_t nRow = 0; nRow < nLineCnt; ++nRow ) { - SwTableLine* pLine = aLines[nRow]; + SwTableLine* pLine = m_aLines[nRow]; const size_t nCols = pLine->GetTabBoxes().size(); long nRight = 0; for( size_t nCurrBox = 0; nCurrBox < nCols; ++nCurrBox ) diff --git a/sw/source/core/table/swtable.cxx b/sw/source/core/table/swtable.cxx index 7004466..76043c6 100644 --- a/sw/source/core/table/swtable.cxx +++ b/sw/source/core/table/swtable.cxx @@ -212,27 +212,27 @@ void _InsTableBox( SwDoc* pDoc, SwTableNode* pTableNd, SwTable::SwTable( SwTableFormat* pFormat ) : SwClient( pFormat ), - pHTMLLayout( 0 ), - pTableNode( 0 ), - nGrfsThatResize( 0 ), - nRowsToRepeat( 1 ), - bModifyLocked( false ), - bNewModel( true ) + m_pHTMLLayout( 0 ), + m_pTableNode( 0 ), + m_nGraphicsThatResize( 0 ), + m_nRowsToRepeat( 1 ), + m_bModifyLocked( false ), + m_bNewModel( true ) { // default value set in the options - eTableChgMode = (TableChgMode)GetTableChgDefaultMode(); + m_eTableChgMode = (TableChgMode)GetTableChgDefaultMode(); } SwTable::SwTable( const SwTable& rTable ) : SwClient( rTable.GetFrameFormat() ), - pHTMLLayout( 0 ), - pTableNode( 0 ), - eTableChgMode( rTable.eTableChgMode ), - nGrfsThatResize( 0 ), - nRowsToRepeat( rTable.GetRowsToRepeat() ), + m_pHTMLLayout( 0 ), + m_pTableNode( 0 ), + m_eTableChgMode( rTable.m_eTableChgMode ), + m_nGraphicsThatResize( 0 ), + m_nRowsToRepeat( rTable.GetRowsToRepeat() ), maTableStyleName(rTable.maTableStyleName), - bModifyLocked( false ), - bNewModel( rTable.bNewModel ) + m_bModifyLocked( false ), + m_bNewModel( rTable.m_bNewModel ) { } @@ -246,13 +246,13 @@ void DelBoxNode( SwTableSortBoxes& rSortCntBoxes ) SwTable::~SwTable() { - if( refObj.Is() ) + if( m_xRefObj.Is() ) { SwDoc* pDoc = GetFrameFormat()->GetDoc(); if( !pDoc->IsInDtor() ) // then remove from the list - pDoc->getIDocumentLinksAdministration().GetLinkManager().RemoveServer( &refObj ); + pDoc->getIDocumentLinksAdministration().GetLinkManager().RemoveServer( &m_xRefObj ); - refObj->Closed(); + m_xRefObj->Closed(); } // the table can be deleted if it's the last client of the FrameFormat @@ -268,7 +268,7 @@ SwTable::~SwTable() // section need deletion. DelBoxNode(m_TabSortContentBoxes); m_TabSortContentBoxes.clear(); - delete pHTMLLayout; + delete m_pHTMLLayout; } namespace @@ -381,8 +381,8 @@ void SwTable::Modify( const SfxPoolItem* pOld, const SfxPoolItem *pNew ) void SwTable::AdjustWidths( const long nOld, const long nNew ) { std::vector<SwFormat*> aFormatArr; - aFormatArr.reserve( aLines[0]->GetTabBoxes().size() ); - ::lcl_ModifyLines( aLines, nOld, nNew, aFormatArr, true ); + aFormatArr.reserve( m_aLines[0]->GetTabBoxes().size() ); + ::lcl_ModifyLines( m_aLines, nOld, nNew, aFormatArr, true ); } static void lcl_RefreshHidden( SwTabCols &rToFill, size_t nPos ) @@ -600,8 +600,8 @@ void SwTable::GetTabCols( SwTabCols &rToFill, const SwTableBox *pStart, // 4. if ( !bCurRowOnly ) { - for ( size_t i = 0; i < aLines.size(); ++i ) - ::lcl_ProcessLineGet( aLines[i], rToFill, pTabFormat ); + for ( size_t i = 0; i < m_aLines.size(); ++i ) + ::lcl_ProcessLineGet( m_aLines[i], rToFill, pTabFormat ); } rToFill.Remove( 0 ); @@ -991,9 +991,9 @@ void SwTable::SetTabCols( const SwTabCols &rNew, const SwTabCols &rOld, { // do some checking for correct table widths SwTwips nSize = GetFrameFormat()->GetFrmSize().GetWidth(); - for (size_t n = 0; n < aLines.size(); ++n) + for (size_t n = 0; n < m_aLines.size(); ++n) { - _CheckBoxWidth( *aLines[ n ], nSize ); + _CheckBoxWidth( *m_aLines[ n ], nSize ); } } #endif @@ -1950,21 +1950,21 @@ SwTableNode* SwTable::GetTableNode() const { return !GetTabSortBoxes().empty() ? const_cast<SwTableNode*>(GetTabSortBoxes()[ 0 ]->GetSttNd()->FindTableNode()) : - pTableNode; + m_pTableNode; } void SwTable::SetRefObject( SwServerObject* pObj ) { - if( refObj.Is() ) - refObj->Closed(); + if( m_xRefObj.Is() ) + m_xRefObj->Closed(); - refObj = pObj; + m_xRefObj = pObj; } void SwTable::SetHTMLTableLayout( SwHTMLTableLayout *p ) { - delete pHTMLLayout; - pHTMLLayout = p; + delete m_pHTMLLayout; + m_pHTMLLayout = p; } void ChgTextToNum( SwTableBox& rBox, const OUString& rText, const Color* pCol, commit 9de42b46104c268d1b391017b891e2150e7f47dd Author: Miklos Vajna <vmik...@collabora.co.uk> Date: Mon Oct 19 09:16:03 2015 +0200 sw: prefix members of SwXAutoStyles Change-Id: Ie6c05a9e63c18275eaf01952add9068c2b46d4e7 diff --git a/sw/inc/unostyle.hxx b/sw/inc/unostyle.hxx index 58d7b64..573b9fab 100644 --- a/sw/inc/unostyle.hxx +++ b/sw/inc/unostyle.hxx @@ -326,11 +326,11 @@ class SwXAutoStyles : public cppu::WeakImplHelper< ::com::sun::star::style::XAutoStyles >, public SwUnoCollection { - SwDocShell *pDocShell; - ::com::sun::star::uno::Reference< ::com::sun::star::style::XAutoStyleFamily > xAutoCharStyles; - ::com::sun::star::uno::Reference< ::com::sun::star::style::XAutoStyleFamily > xAutoRubyStyles; - ::com::sun::star::uno::Reference< ::com::sun::star::style::XAutoStyleFamily > xAutoParaStyles; - ::com::sun::star::uno::Reference< ::com::sun::star::style::XAutoStyleFamily > xAutoNotxtStyles; + SwDocShell *m_pDocShell; + ::com::sun::star::uno::Reference< ::com::sun::star::style::XAutoStyleFamily > m_xAutoCharStyles; + ::com::sun::star::uno::Reference< ::com::sun::star::style::XAutoStyleFamily > m_xAutoRubyStyles; + ::com::sun::star::uno::Reference< ::com::sun::star::style::XAutoStyleFamily > m_xAutoParaStyles; + ::com::sun::star::uno::Reference< ::com::sun::star::style::XAutoStyleFamily > m_xAutoNotxtStyles; virtual ~SwXAutoStyles(); public: diff --git a/sw/source/core/unocore/unostyle.cxx b/sw/source/core/unocore/unostyle.cxx index b540549..4252058 100644 --- a/sw/source/core/unocore/unostyle.cxx +++ b/sw/source/core/unocore/unostyle.cxx @@ -4033,7 +4033,7 @@ uno::Reference< container::XNameReplace > SwXFrameStyle::getEvents( ) throw(uno } SwXAutoStyles::SwXAutoStyles(SwDocShell& rDocShell) : - SwUnoCollection(rDocShell.GetDoc()), pDocShell( &rDocShell ) + SwUnoCollection(rDocShell.GetDoc()), m_pDocShell( &rDocShell ) { } @@ -4062,23 +4062,23 @@ uno::Any SwXAutoStyles::getByIndex(sal_Int32 nIndex) { case IStyleAccess::AUTO_STYLE_CHAR: { - if(!xAutoCharStyles.is()) - xAutoCharStyles = new SwXAutoStyleFamily(pDocShell, nType); - aRef = xAutoCharStyles; + if(!m_xAutoCharStyles.is()) + m_xAutoCharStyles = new SwXAutoStyleFamily(m_pDocShell, nType); + aRef = m_xAutoCharStyles; } break; case IStyleAccess::AUTO_STYLE_RUBY: { - if(!xAutoRubyStyles.is()) - xAutoRubyStyles = new SwXAutoStyleFamily(pDocShell, nType ); - aRef = xAutoRubyStyles; + if(!m_xAutoRubyStyles.is()) + m_xAutoRubyStyles = new SwXAutoStyleFamily(m_pDocShell, nType ); + aRef = m_xAutoRubyStyles; } break; case IStyleAccess::AUTO_STYLE_PARA: { - if(!xAutoParaStyles.is()) - xAutoParaStyles = new SwXAutoStyleFamily(pDocShell, nType ); - aRef = xAutoParaStyles; + if(!m_xAutoParaStyles.is()) + m_xAutoParaStyles = new SwXAutoStyleFamily(m_pDocShell, nType ); + aRef = m_xAutoParaStyles; } break; commit ca0d0f65c616b3ad56e41812870129e060e8dadc Author: Miklos Vajna <vmik...@collabora.co.uk> Date: Mon Oct 19 09:15:12 2015 +0200 sw: prefix members of SwXStyle Change-Id: I0f80f52c31c68521b89faf123e45ce458883d76b diff --git a/sw/inc/unostyle.hxx b/sw/inc/unostyle.hxx index 4b75ead..58d7b64 100644 --- a/sw/inc/unostyle.hxx +++ b/sw/inc/unostyle.hxx @@ -168,23 +168,23 @@ class SwXStyle : public cppu::WeakImplHelper friend class SwXStyleFamily; SwDoc* m_pDoc; OUString m_sStyleName; - SfxStyleSheetBasePool* pBasePool; - SfxStyleFamily eFamily; // for Notify + SfxStyleSheetBasePool* m_pBasePool; + SfxStyleFamily m_eFamily; // for Notify - bool bIsDescriptor : 1; - bool bIsConditional : 1; + bool m_bIsDescriptor : 1; + bool m_bIsConditional : 1; OUString m_sParentStyleName; - SwStyleProperties_Impl* pPropImpl; + SwStyleProperties_Impl* m_pPropertiesImpl; void ApplyDescriptorProperties(); protected: void Invalidate(); - const SfxStyleSheetBasePool* GetBasePool() const {return pBasePool;} - SfxStyleSheetBasePool* GetBasePool() {return pBasePool;} + const SfxStyleSheetBasePool* GetBasePool() const {return m_pBasePool;} + SfxStyleSheetBasePool* GetBasePool() {return m_pBasePool;} void SetStyleName(const OUString& rSet){ m_sStyleName = rSet;} - SwStyleProperties_Impl* GetPropImpl(){return pPropImpl;} + SwStyleProperties_Impl* GetPropImpl(){return m_pPropertiesImpl;} com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > mxStyleData; com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess > mxStyleFamily; @@ -259,16 +259,16 @@ public: virtual void Notify( SfxBroadcaster& rBC, const SfxHint& rHint ) override; OUString GetStyleName() const { return m_sStyleName;} - SfxStyleFamily GetFamily() const {return eFamily;} + SfxStyleFamily GetFamily() const {return m_eFamily;} - bool IsDescriptor() const {return bIsDescriptor;} - bool IsConditional() const { return bIsConditional;} + bool IsDescriptor() const {return m_bIsDescriptor;} + bool IsConditional() const { return m_bIsConditional;} OUString GetParentStyleName() const { return m_sParentStyleName;} void SetDoc(SwDoc* pDc, SfxStyleSheetBasePool* pPool) { - bIsDescriptor = false; m_pDoc = pDc; - pBasePool = pPool; - StartListening(*pBasePool); + m_bIsDescriptor = false; m_pDoc = pDc; + m_pBasePool = pPool; + StartListening(*m_pBasePool); } SwDoc* GetDoc() const { return m_pDoc; } }; diff --git a/sw/source/core/unocore/unostyle.cxx b/sw/source/core/unocore/unostyle.cxx index d297a26..b540549 100644 --- a/sw/source/core/unocore/unostyle.cxx +++ b/sw/source/core/unocore/unostyle.cxx @@ -1175,20 +1175,20 @@ sal_Bool SwXStyle::supportsService(const OUString& rServiceName) throw( uno::Run uno::Sequence< OUString > SwXStyle::getSupportedServiceNames() throw( uno::RuntimeException, std::exception ) { long nCount = 1; - if(SFX_STYLE_FAMILY_PARA == eFamily) + if(SFX_STYLE_FAMILY_PARA == m_eFamily) { nCount = 5; - if(bIsConditional) + if(m_bIsConditional) nCount++; } - else if(SFX_STYLE_FAMILY_CHAR == eFamily) + else if(SFX_STYLE_FAMILY_CHAR == m_eFamily) nCount = 5; - else if(SFX_STYLE_FAMILY_PAGE == eFamily) + else if(SFX_STYLE_FAMILY_PAGE == m_eFamily) nCount = 3; uno::Sequence< OUString > aRet(nCount); OUString* pArray = aRet.getArray(); pArray[0] = "com.sun.star.style.Style"; - switch(eFamily) + switch(m_eFamily) { case SFX_STYLE_FAMILY_CHAR: pArray[1] = "com.sun.star.style.CharacterStyle"; @@ -1205,7 +1205,7 @@ uno::Sequence< OUString > SwXStyle::getSupportedServiceNames() throw( uno::Runti pArray[2] = "com.sun.star.style.ParagraphProperties"; pArray[3] = "com.sun.star.style.ParagraphPropertiesAsian"; pArray[4] = "com.sun.star.style.ParagraphPropertiesComplex"; - if(bIsConditional) + if(m_bIsConditional) pArray[5] = "com.sun.star.style.ConditionalParagraphStyle"; break; @@ -1217,10 +1217,10 @@ uno::Sequence< OUString > SwXStyle::getSupportedServiceNames() throw( uno::Runti SwXStyle::SwXStyle( SwDoc *pDoc, SfxStyleFamily eFam, bool bConditional) : m_pDoc( pDoc ), - pBasePool(0), - eFamily(eFam), - bIsDescriptor(true), - bIsConditional(bConditional) + m_pBasePool(0), + m_eFamily(eFam), + m_bIsDescriptor(true), + m_bIsConditional(bConditional) { // Register ourselves as a listener to the document (via the page descriptor) pDoc->getIDocumentStylePoolAccess().GetPageDescFromPool(RES_POOLPAGE_STANDARD)->Add(this); @@ -1234,7 +1234,7 @@ SwXStyle::SwXStyle( SwDoc *pDoc, SfxStyleFamily eFam, bool bConditional) : uno::Any aAny; sal_uInt16 nMapId = PROPERTY_MAP_NUM_STYLE; - switch( eFamily ) + switch( m_eFamily ) { case SFX_STYLE_FAMILY_CHAR: { @@ -1246,7 +1246,7 @@ SwXStyle::SwXStyle( SwDoc *pDoc, SfxStyleFamily eFam, bool bConditional) : break; case SFX_STYLE_FAMILY_PARA: { - nMapId = bIsConditional ? PROPERTY_MAP_CONDITIONAL_PARA_STYLE : PROPERTY_MAP_PARA_STYLE; + nMapId = m_bIsConditional ? PROPERTY_MAP_CONDITIONAL_PARA_STYLE : PROPERTY_MAP_PARA_STYLE; aAny = xFamilies->getByName ("ParagraphStyles"); // Get the Frame family (and keep it for later) aAny >>= mxStyleFamily; @@ -1278,32 +1278,32 @@ SwXStyle::SwXStyle( SwDoc *pDoc, SfxStyleFamily eFam, bool bConditional) : default: ; } - pPropImpl = new SwStyleProperties_Impl(aSwMapProvider.GetPropertySet(nMapId)->getPropertyMap()); + m_pPropertiesImpl = new SwStyleProperties_Impl(aSwMapProvider.GetPropertySet(nMapId)->getPropertyMap()); } SwXStyle::SwXStyle(SfxStyleSheetBasePool& rPool, SfxStyleFamily eFam, SwDoc* pDoc, const OUString& rStyleName) : m_pDoc(pDoc), m_sStyleName(rStyleName), - pBasePool(&rPool), - eFamily(eFam), - bIsDescriptor(false), - bIsConditional(false), - pPropImpl(0) + m_pBasePool(&rPool), + m_eFamily(eFam), + m_bIsDescriptor(false), + m_bIsConditional(false), + m_pPropertiesImpl(0) { StartListening(rPool); if(eFam == SFX_STYLE_FAMILY_PARA) { - pBasePool->SetSearchMask(eFamily); - SfxStyleSheetBase* pBase = pBasePool->Find(m_sStyleName); + m_pBasePool->SetSearchMask(m_eFamily); + SfxStyleSheetBase* pBase = m_pBasePool->Find(m_sStyleName); OSL_ENSURE(pBase, "where is the style?" ); if(pBase) { const sal_uInt16 nId = SwStyleNameMapper::GetPoolIdFromUIName(m_sStyleName, nsSwGetPoolIdFromName::GET_POOLID_TXTCOLL); if(nId != USHRT_MAX) - bIsConditional = ::IsConditionalByPoolId( nId ); + m_bIsConditional = ::IsConditionalByPoolId( nId ); else - bIsConditional = RES_CONDTXTFMTCOLL == static_cast<SwDocStyleSheet*>(pBase)->GetCollection()->Which(); + m_bIsConditional = RES_CONDTXTFMTCOLL == static_cast<SwDocStyleSheet*>(pBase)->GetCollection()->Which(); } } } @@ -1311,9 +1311,9 @@ SwXStyle::SwXStyle(SfxStyleSheetBasePool& rPool, SfxStyleFamily eFam, SwXStyle::~SwXStyle() { SolarMutexGuard aGuard; - if(pBasePool) - EndListening(*pBasePool); - delete pPropImpl; + if(m_pBasePool) + EndListening(*m_pBasePool); + delete m_pPropertiesImpl; } void SwXStyle::Modify( const SfxPoolItem* pOld, const SfxPoolItem *pNew) @@ -1330,15 +1330,15 @@ void SwXStyle::Modify( const SfxPoolItem* pOld, const SfxPoolItem *pNew) OUString SwXStyle::getName() throw( uno::RuntimeException, std::exception ) { SolarMutexGuard aGuard; - if(pBasePool) + if(m_pBasePool) { - pBasePool->SetSearchMask(eFamily); - SfxStyleSheetBase* pBase = pBasePool->Find(m_sStyleName); + m_pBasePool->SetSearchMask(m_eFamily); + SfxStyleSheetBase* pBase = m_pBasePool->Find(m_sStyleName); OSL_ENSURE(pBase, "where is the style?" ); if(!pBase) throw uno::RuntimeException(); OUString aString; - SwStyleNameMapper::FillProgName(pBase->GetName(), aString, lcl_GetSwEnumFromSfxEnum ( eFamily ), true); + SwStyleNameMapper::FillProgName(pBase->GetName(), aString, lcl_GetSwEnumFromSfxEnum ( m_eFamily ), true); return aString; } return m_sStyleName; @@ -1347,10 +1347,10 @@ OUString SwXStyle::getName() throw( uno::RuntimeException, std::exception ) void SwXStyle::setName(const OUString& rName) throw( uno::RuntimeException, std::exception ) { SolarMutexGuard aGuard; - if(pBasePool) + if(m_pBasePool) { - pBasePool->SetSearchMask(eFamily); - SfxStyleSheetBase* pBase = pBasePool->Find(m_sStyleName); + m_pBasePool->SetSearchMask(m_eFamily); + SfxStyleSheetBase* pBase = m_pBasePool->Find(m_sStyleName); OSL_ENSURE(pBase, "where is the style?" ); bool bExcept = true; if(pBase && pBase->IsUserDefined()) @@ -1371,10 +1371,10 @@ sal_Bool SwXStyle::isUserDefined() throw( uno::RuntimeException, std::exception { SolarMutexGuard aGuard; bool bRet = false; - if(pBasePool) + if(m_pBasePool) { - pBasePool->SetSearchMask(eFamily); - SfxStyleSheetBase* pBase = pBasePool->Find(m_sStyleName); + m_pBasePool->SetSearchMask(m_eFamily); + SfxStyleSheetBase* pBase = m_pBasePool->Find(m_sStyleName); //if it is not found it must be non user defined if(pBase) bRet = pBase->IsUserDefined(); @@ -1388,10 +1388,10 @@ sal_Bool SwXStyle::isInUse() throw( uno::RuntimeException, std::exception ) { SolarMutexGuard aGuard; bool bRet = false; - if(pBasePool) + if(m_pBasePool) { - pBasePool->SetSearchMask(eFamily, SFXSTYLEBIT_USED); - SfxStyleSheetBase* pBase = pBasePool->Find(m_sStyleName); + m_pBasePool->SetSearchMask(m_eFamily, SFXSTYLEBIT_USED); + SfxStyleSheetBase* pBase = m_pBasePool->Find(m_sStyleName); if(pBase) bRet = pBase->IsUsed(); } @@ -1404,18 +1404,18 @@ OUString SwXStyle::getParentStyle() throw( uno::RuntimeException, std::exception { SolarMutexGuard aGuard; OUString aString; - if(pBasePool) + if(m_pBasePool) { - pBasePool->SetSearchMask(eFamily); - SfxStyleSheetBase* pBase = pBasePool->Find(m_sStyleName); + m_pBasePool->SetSearchMask(m_eFamily); + SfxStyleSheetBase* pBase = m_pBasePool->Find(m_sStyleName); if(pBase) aString = pBase->GetParent(); } - else if(bIsDescriptor) + else if(m_bIsDescriptor) aString = m_sParentStyleName; else throw uno::RuntimeException(); - SwStyleNameMapper::FillProgName(aString, aString, lcl_GetSwEnumFromSfxEnum ( eFamily ), true ); + SwStyleNameMapper::FillProgName(aString, aString, lcl_GetSwEnumFromSfxEnum ( m_eFamily ), true ); return aString; } @@ -1424,12 +1424,12 @@ void SwXStyle::setParentStyle(const OUString& rParentStyle) { SolarMutexGuard aGuard; OUString sParentStyle; - SwStyleNameMapper::FillUIName(rParentStyle, sParentStyle, lcl_GetSwEnumFromSfxEnum ( eFamily ), true ); - if(pBasePool) + SwStyleNameMapper::FillUIName(rParentStyle, sParentStyle, lcl_GetSwEnumFromSfxEnum ( m_eFamily ), true ); + if(m_pBasePool) { - pBasePool->SetSearchMask(eFamily); + m_pBasePool->SetSearchMask(m_eFamily); bool bExcept = false; - SfxStyleSheetBase* pBase = pBasePool->Find(m_sStyleName); + SfxStyleSheetBase* pBase = m_pBasePool->Find(m_sStyleName); if(pBase) { rtl::Reference< SwDocStyleSheet > xBase( new SwDocStyleSheet(*static_cast<SwDocStyleSheet*>(pBase)) ); @@ -1445,7 +1445,7 @@ void SwXStyle::setParentStyle(const OUString& rParentStyle) if(bExcept) throw uno::RuntimeException(); } - else if(bIsDescriptor) + else if(m_bIsDescriptor) { m_sParentStyleName = sParentStyle; try @@ -1536,21 +1536,21 @@ static uno::Reference< beans::XPropertySetInfo > lcl_getPropertySetInfo( SfxStyl uno::Reference< beans::XPropertySetInfo > SwXStyle::getPropertySetInfo() throw( uno::RuntimeException, std::exception ) { - return lcl_getPropertySetInfo( eFamily, bIsConditional ); + return lcl_getPropertySetInfo( m_eFamily, m_bIsConditional ); } void SwXStyle::ApplyDescriptorProperties() { - bIsDescriptor = false; + m_bIsDescriptor = false; mxStyleData.clear(); mxStyleFamily.clear(); - const PropertyEntryVector_t& rPropertyVector = pPropImpl->GetPropertyVector(); + const PropertyEntryVector_t& rPropertyVector = m_pPropertiesImpl->GetPropertyVector(); PropertyEntryVector_t::const_iterator aIt = rPropertyVector.begin(); while(aIt != rPropertyVector.end()) { uno::Any* pAny(0); - pPropImpl->GetProperty(aIt->sName, pAny); + m_pPropertiesImpl->GetProperty(aIt->sName, pAny); if (pAny) setPropertyValue(aIt->sName, *pAny); ++aIt; @@ -2237,9 +2237,9 @@ void SAL_CALL SwXStyle::SetPropertyValues_Impl( sal_Int8 nPropSetId = PROPERTY_MAP_CHAR_STYLE; - switch(eFamily) + switch(m_eFamily) { - case SFX_STYLE_FAMILY_PARA : nPropSetId = bIsConditional ? PROPERTY_MAP_CONDITIONAL_PARA_STYLE : PROPERTY_MAP_PARA_STYLE; break; + case SFX_STYLE_FAMILY_PARA : nPropSetId = m_bIsConditional ? PROPERTY_MAP_CONDITIONAL_PARA_STYLE : PROPERTY_MAP_PARA_STYLE; break; case SFX_STYLE_FAMILY_FRAME : nPropSetId = PROPERTY_MAP_FRAME_STYLE ;break; case SFX_STYLE_FAMILY_PAGE : nPropSetId = PROPERTY_MAP_PAGE_STYLE ;break; case SFX_STYLE_FAMILY_PSEUDO: nPropSetId = PROPERTY_MAP_NUM_STYLE ;break; @@ -2257,12 +2257,12 @@ void SAL_CALL SwXStyle::SetPropertyValues_Impl( const uno::Any* pValues = rValues.getConstArray(); SwStyleBase_Impl aBaseImpl(*m_pDoc, m_sStyleName, &GetDoc()->GetDfltTextFormatColl()->GetAttrSet()); //UUUU add pDfltTextFormatColl as parent - if(pBasePool) + if(m_pBasePool) { - const sal_uInt16 nSaveMask = pBasePool->GetSearchMask(); - pBasePool->SetSearchMask(eFamily); - SfxStyleSheetBase* pBase = pBasePool->Find(m_sStyleName); - pBasePool->SetSearchMask(eFamily, nSaveMask ); + const sal_uInt16 nSaveMask = m_pBasePool->GetSearchMask(); + m_pBasePool->SetSearchMask(m_eFamily); + SfxStyleSheetBase* pBase = m_pBasePool->Find(m_sStyleName); + m_pBasePool->SetSearchMask(m_eFamily, nSaveMask ); OSL_ENSURE(pBase, "where is the style?" ); if(pBase) aBaseImpl.setNewBase(new SwDocStyleSheet(*static_cast<SwDocStyleSheet*>(pBase))); @@ -2275,17 +2275,17 @@ void SAL_CALL SwXStyle::SetPropertyValues_Impl( const SfxItemPropertySimpleEntry* pEntry = rMap.getByName(pNames[nProp]); if(!pEntry || - (!bIsConditional && pNames[nProp] == UNO_NAME_PARA_STYLE_CONDITIONS)) + (!m_bIsConditional && pNames[nProp] == UNO_NAME_PARA_STYLE_CONDITIONS)) throw beans::UnknownPropertyException("Unknown property: " + pNames[nProp], static_cast < cppu::OWeakObject * > ( this ) ); if ( pEntry->nFlags & beans::PropertyAttribute::READONLY) throw beans::PropertyVetoException ("Property is read-only: " + pNames[nProp], static_cast < cppu::OWeakObject * > ( this ) ); if(aBaseImpl.getNewBase().is()) { - lcl_SetStyleProperty(*pEntry, *pPropSet, pValues[nProp], aBaseImpl, pBasePool, m_pDoc, eFamily); + lcl_SetStyleProperty(*pEntry, *pPropSet, pValues[nProp], aBaseImpl, m_pBasePool, m_pDoc, m_eFamily); } - else if(bIsDescriptor) + else if(m_bIsDescriptor) { - if(!pPropImpl->SetProperty(pNames[nProp], pValues[nProp])) + if(!m_pPropertiesImpl->SetProperty(pNames[nProp], pValues[nProp])) { throw lang::IllegalArgumentException(); } @@ -2650,9 +2650,9 @@ uno::Sequence< uno::Any > SAL_CALL SwXStyle::GetPropertyValues_Impl( sal_Int8 nPropSetId = PROPERTY_MAP_CHAR_STYLE; - switch(eFamily) + switch(m_eFamily) { - case SFX_STYLE_FAMILY_PARA : nPropSetId = bIsConditional ? PROPERTY_MAP_CONDITIONAL_PARA_STYLE : PROPERTY_MAP_PARA_STYLE; break; + case SFX_STYLE_FAMILY_PARA : nPropSetId = m_bIsConditional ? PROPERTY_MAP_CONDITIONAL_PARA_STYLE : PROPERTY_MAP_PARA_STYLE; break; case SFX_STYLE_FAMILY_FRAME : nPropSetId = PROPERTY_MAP_FRAME_STYLE ;break; case SFX_STYLE_FAMILY_PAGE : nPropSetId = PROPERTY_MAP_PAGE_STYLE ;break; case SFX_STYLE_FAMILY_PSEUDO: nPropSetId = PROPERTY_MAP_NUM_STYLE ;break; @@ -2671,29 +2671,29 @@ uno::Sequence< uno::Any > SAL_CALL SwXStyle::GetPropertyValues_Impl( { const SfxItemPropertySimpleEntry* pEntry = rMap.getByName( pNames[nProp]); if(!pEntry || - (!bIsConditional && pNames[nProp] == UNO_NAME_PARA_STYLE_CONDITIONS)) + (!m_bIsConditional && pNames[nProp] == UNO_NAME_PARA_STYLE_CONDITIONS)) throw beans::UnknownPropertyException("Unknown property: " + pNames[nProp], static_cast < cppu::OWeakObject * > ( this ) ); - if(pBasePool) + if(m_pBasePool) { if(!pBase) { - const sal_uInt16 nSaveMask = pBasePool->GetSearchMask(); - pBasePool->SetSearchMask(eFamily); - pBase = pBasePool->Find(m_sStyleName); - pBasePool->SetSearchMask(eFamily, nSaveMask ); + const sal_uInt16 nSaveMask = m_pBasePool->GetSearchMask(); + m_pBasePool->SetSearchMask(m_eFamily); + pBase = m_pBasePool->Find(m_sStyleName); + m_pBasePool->SetSearchMask(m_eFamily, nSaveMask ); } - pRet[nProp] = lcl_GetStyleProperty(*pEntry, *pPropSet, aBase, pBase, eFamily, GetDoc() ); + pRet[nProp] = lcl_GetStyleProperty(*pEntry, *pPropSet, aBase, pBase, m_eFamily, GetDoc() ); } - else if(bIsDescriptor) + else if(m_bIsDescriptor) { uno::Any *pAny = 0; - pPropImpl->GetProperty ( pNames[nProp], pAny ); + m_pPropertiesImpl->GetProperty ( pNames[nProp], pAny ); if( !pAny ) { bool bExcept = false; - switch( eFamily ) + switch( m_eFamily ) { case SFX_STYLE_FAMILY_PSEUDO: bExcept = true; @@ -2708,7 +2708,7 @@ uno::Sequence< uno::Any > SAL_CALL SwXStyle::GetPropertyValues_Impl( if (pEntry->nWID >= POOLATTR_BEGIN && pEntry->nWID < RES_UNKNOWNATR_END ) { SwFormat * pFormat; - if ( eFamily == SFX_STYLE_FAMILY_CHAR ) + if ( m_eFamily == SFX_STYLE_FAMILY_CHAR ) pFormat = m_pDoc->GetDfltCharFormat(); else pFormat = m_pDoc->GetDfltFrameFormat(); @@ -2853,10 +2853,10 @@ uno::Sequence< beans::PropertyState > SwXStyle::getPropertyStates( uno::Sequence< beans::PropertyState > aRet(rPropertyNames.getLength()); beans::PropertyState* pStates = aRet.getArray(); - if(pBasePool) + if(m_pBasePool) { - pBasePool->SetSearchMask(eFamily ); - SfxStyleSheetBase* pBase = pBasePool->Find(m_sStyleName); + m_pBasePool->SetSearchMask(m_eFamily ); + SfxStyleSheetBase* pBase = m_pBasePool->Find(m_sStyleName); OSL_ENSURE(pBase, "where is the style?" ); if(pBase) @@ -2865,9 +2865,9 @@ uno::Sequence< beans::PropertyState > SwXStyle::getPropertyStates( rtl::Reference< SwDocStyleSheet > xStyle( new SwDocStyleSheet( *static_cast<SwDocStyleSheet*>(pBase) ) ); sal_Int8 nPropSetId = PROPERTY_MAP_CHAR_STYLE; - switch(eFamily) + switch(m_eFamily) { - case SFX_STYLE_FAMILY_PARA : nPropSetId = bIsConditional ? PROPERTY_MAP_CONDITIONAL_PARA_STYLE : PROPERTY_MAP_PARA_STYLE; break; + case SFX_STYLE_FAMILY_PARA : nPropSetId = m_bIsConditional ? PROPERTY_MAP_CONDITIONAL_PARA_STYLE : PROPERTY_MAP_PARA_STYLE; break; case SFX_STYLE_FAMILY_FRAME : nPropSetId = PROPERTY_MAP_FRAME_STYLE ;break; case SFX_STYLE_FAMILY_PAGE : nPropSetId = PROPERTY_MAP_PAGE_STYLE; break; case SFX_STYLE_FAMILY_PSEUDO: nPropSetId = PROPERTY_MAP_NUM_STYLE ;break; @@ -2903,8 +2903,8 @@ uno::Sequence< beans::PropertyState > SwXStyle::getPropertyStates( if(!bDone) { // check for Header/Footer entry - const bool bHeader(SFX_STYLE_FAMILY_PAGE == eFamily && sPropName.startsWith("Header")); - const bool bFooter(SFX_STYLE_FAMILY_PAGE == eFamily && sPropName.startsWith("Footer")); + const bool bHeader(SFX_STYLE_FAMILY_PAGE == m_eFamily && sPropName.startsWith("Header")); + const bool bFooter(SFX_STYLE_FAMILY_PAGE == m_eFamily && sPropName.startsWith("Footer")); if(bHeader || bFooter || sPropName == UNO_NAME_FIRST_IS_SHARED) { @@ -2961,7 +2961,7 @@ uno::Sequence< beans::PropertyState > SwXStyle::getPropertyStates( { pStates[i] = pPropSet->getPropertyState(*pEntry, *pSourceSet); - if(SFX_STYLE_FAMILY_PAGE == eFamily && SID_ATTR_PAGE_SIZE == pEntry->nWID && beans::PropertyState_DIRECT_VALUE == pStates[i]) + if(SFX_STYLE_FAMILY_PAGE == m_eFamily && SID_ATTR_PAGE_SIZE == pEntry->nWID && beans::PropertyState_DIRECT_VALUE == pStates[i]) { const SvxSizeItem& rSize = static_cast <const SvxSizeItem&>( rSet.Get(SID_ATTR_PAGE_SIZE)); sal_uInt8 nMemberId = pEntry->nMemberId & 0x7f; @@ -3004,16 +3004,16 @@ void SAL_CALL SwXStyle::setPropertiesToDefault( const uno::Sequence< OUString >& SolarMutexGuard aGuard; SwFormat *pTargetFormat = 0; - if(pBasePool) + if(m_pBasePool) { - pBasePool->SetSearchMask(eFamily); - SfxStyleSheetBase* pBase = pBasePool->Find(m_sStyleName); + m_pBasePool->SetSearchMask(m_eFamily); + SfxStyleSheetBase* pBase = m_pBasePool->Find(m_sStyleName); OSL_ENSURE(pBase, "Where is the style?"); if(pBase) { rtl::Reference< SwDocStyleSheet > xStyle( new SwDocStyleSheet( *static_cast<SwDocStyleSheet*>(pBase) ) ); - switch(eFamily) + switch(m_eFamily) { case SFX_STYLE_FAMILY_CHAR: pTargetFormat = xStyle->GetCharFormat(); @@ -3043,9 +3043,9 @@ void SAL_CALL SwXStyle::setPropertiesToDefault( const uno::Sequence< OUString >& sal_Int8 nPropSetId = PROPERTY_MAP_CHAR_STYLE; - switch(eFamily) + switch(m_eFamily) { - case SFX_STYLE_FAMILY_PARA : nPropSetId = bIsConditional ? PROPERTY_MAP_CONDITIONAL_PARA_STYLE : PROPERTY_MAP_PARA_STYLE; break; + case SFX_STYLE_FAMILY_PARA : nPropSetId = m_bIsConditional ? PROPERTY_MAP_CONDITIONAL_PARA_STYLE : PROPERTY_MAP_PARA_STYLE; break; case SFX_STYLE_FAMILY_FRAME : nPropSetId = PROPERTY_MAP_FRAME_STYLE; break; case SFX_STYLE_FAMILY_PAGE : nPropSetId = PROPERTY_MAP_PAGE_STYLE; break; case SFX_STYLE_FAMILY_PSEUDO: nPropSetId = PROPERTY_MAP_NUM_STYLE; break; @@ -3100,11 +3100,11 @@ void SAL_CALL SwXStyle::setPropertiesToDefault( const uno::Sequence< OUString >& } } } - else if(bIsDescriptor) + else if(m_bIsDescriptor) { for(sal_Int32 nProp = 0, nEnd = aPropertyNames.getLength(); nProp < nEnd; nProp++) { - pPropImpl->ClearProperty(pNames[nProp]); + m_pPropertiesImpl->ClearProperty(pNames[nProp]); } } } @@ -3114,10 +3114,10 @@ void SAL_CALL SwXStyle::setAllPropertiesToDefault( ) { SolarMutexGuard aGuard; - if(pBasePool) + if(m_pBasePool) { - pBasePool->SetSearchMask(eFamily); - SfxStyleSheetBase* pBase = pBasePool->Find(m_sStyleName); + m_pBasePool->SetSearchMask(m_eFamily); + SfxStyleSheetBase* pBase = m_pBasePool->Find(m_sStyleName); OSL_ENSURE(pBase, "Where is the style?"); if(pBase) @@ -3125,7 +3125,7 @@ void SAL_CALL SwXStyle::setAllPropertiesToDefault( ) rtl::Reference< SwDocStyleSheet > xStyle( new SwDocStyleSheet( *static_cast<SwDocStyleSheet*>(pBase) ) ); SwFormat *pTargetFormat = 0; size_t nPgDscPos = SIZE_MAX; - switch(eFamily) + switch(m_eFamily) { case SFX_STYLE_FAMILY_CHAR: pTargetFormat = xStyle->GetCharFormat(); @@ -3225,9 +3225,9 @@ void SAL_CALL SwXStyle::setAllPropertiesToDefault( ) throw uno::RuntimeException(); } } - else if ( bIsDescriptor ) + else if ( m_bIsDescriptor ) { - pPropImpl->ClearAllProperties(); + m_pPropertiesImpl->ClearAllProperties(); } else { @@ -3245,19 +3245,19 @@ uno::Sequence< uno::Any > SAL_CALL SwXStyle::getPropertyDefaults( const uno::Seq if(nCount) { - if(pBasePool) + if(m_pBasePool) { - pBasePool->SetSearchMask(eFamily); - SfxStyleSheetBase* pBase = pBasePool->Find(m_sStyleName); + m_pBasePool->SetSearchMask(m_eFamily); + SfxStyleSheetBase* pBase = m_pBasePool->Find(m_sStyleName); OSL_ENSURE(pBase, "Doesn't seem to be a style!"); if(pBase) { rtl::Reference< SwDocStyleSheet > xStyle(new SwDocStyleSheet(*static_cast<SwDocStyleSheet*>(pBase))); sal_Int8 nPropSetId = PROPERTY_MAP_CHAR_STYLE; - switch(eFamily) + switch(m_eFamily) { - case SFX_STYLE_FAMILY_PARA : nPropSetId = bIsConditional ? PROPERTY_MAP_CONDITIONAL_PARA_STYLE : PROPERTY_MAP_PARA_STYLE; break; + case SFX_STYLE_FAMILY_PARA : nPropSetId = m_bIsConditional ? PROPERTY_MAP_CONDITIONAL_PARA_STYLE : PROPERTY_MAP_PARA_STYLE; break; case SFX_STYLE_FAMILY_FRAME : nPropSetId = PROPERTY_MAP_FRAME_STYLE; break; case SFX_STYLE_FAMILY_PAGE : nPropSetId = PROPERTY_MAP_PAGE_STYLE; break; case SFX_STYLE_FAMILY_PSEUDO: nPropSetId = PROPERTY_MAP_NUM_STYLE; break; @@ -3325,12 +3325,12 @@ void SwXStyle::Notify( SfxBroadcaster& rBC, const SfxHint& rHint ) { if(( pHint->GetId() & SFX_HINT_DYING ) || ( pHint->GetId() & SfxStyleSheetHintId::ERASED)) { - pBasePool = 0; + m_pBasePool = 0; EndListening(rBC); } else if( pHint->GetId() &(SfxStyleSheetHintId::CHANGED|SfxStyleSheetHintId::ERASED) ) { - static_cast<SfxStyleSheetBasePool&>(rBC).SetSearchMask(eFamily); + static_cast<SfxStyleSheetBasePool&>(rBC).SetSearchMask(m_eFamily); SfxStyleSheetBase* pOwnBase = static_cast<SfxStyleSheetBasePool&>(rBC).Find(m_sStyleName); if(!pOwnBase) { @@ -3344,7 +3344,7 @@ void SwXStyle::Notify( SfxBroadcaster& rBC, const SfxHint& rHint ) void SwXStyle::Invalidate() { m_sStyleName.clear(); - pBasePool = 0; + m_pBasePool = 0; m_pDoc = 0; mxStyleData.clear(); mxStyleFamily.clear(); _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits