[Libreoffice-commits] core.git: include/svl sc/source sd/source svl/source sw/source
Stephan Bergmann
sbergman at redhat.com
Sat Apr 7 21:03:23 UTC 2018
include/svl/style.hxx | 4 +--
sc/source/core/data/stlsheet.cxx | 6 ++---
sd/source/core/stlsheet.cxx | 14 ++++++-------
svl/source/items/style.cxx | 40 +++++++++++++++++++-------------------
sw/source/uibase/app/docstyle.cxx | 18 ++++++++---------
5 files changed, 41 insertions(+), 41 deletions(-)
New commits:
commit bcf91144808232fa0d92184d2f1c09e5eaa1e86c
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Sat Apr 7 14:30:26 2018 +0200
Prefix SfxStyleSheetBase::pPool member
...just that one member; came in handy when researching a failure, and don't
want to loose that improvement.
Change-Id: Ia5434c4bd8131c37f93d32ce840859469ac258ef
Reviewed-on: https://gerrit.libreoffice.org/52553
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Stephan Bergmann <sbergman at redhat.com>
diff --git a/include/svl/style.hxx b/include/svl/style.hxx
index 48f0e1cba7ae..b30ddfe82ab1 100644
--- a/include/svl/style.hxx
+++ b/include/svl/style.hxx
@@ -98,7 +98,7 @@ private:
friend class SfxStyleSheetBasePool;
protected:
- SfxStyleSheetBasePool* pPool; // related pool
+ SfxStyleSheetBasePool* m_pPool; // related pool
SfxStyleFamily nFamily;
OUString aName, aParent, aFollow;
@@ -139,7 +139,7 @@ public:
virtual bool IsUsed() const; // Default true
virtual OUString GetDescription( MapUnit eMetric );
- SfxStyleSheetBasePool& GetPool() { return *pPool; }
+ SfxStyleSheetBasePool& GetPool() { return *m_pPool; }
SfxStyleFamily GetFamily() const { return nFamily; }
sal_uInt16 GetMask() const { return nMask; }
void SetMask( sal_uInt16 mask) { nMask = mask; }
diff --git a/sc/source/core/data/stlsheet.cxx b/sc/source/core/data/stlsheet.cxx
index 0e4e5d172533..596a703b5c5f 100644
--- a/sc/source/core/data/stlsheet.cxx
+++ b/sc/source/core/data/stlsheet.cxx
@@ -93,10 +93,10 @@ bool ScStyleSheet::SetParent( const OUString& rParentName )
{
bool bResult = false;
OUString aEffName = rParentName;
- SfxStyleSheetBase* pStyle = pPool->Find( aEffName, nFamily );
+ SfxStyleSheetBase* pStyle = m_pPool->Find( aEffName, nFamily );
if (!pStyle)
{
- std::shared_ptr<SfxStyleSheetIterator> pIter = pPool->CreateIterator( nFamily, SFXSTYLEBIT_ALL );
+ std::shared_ptr<SfxStyleSheetIterator> pIter = m_pPool->CreateIterator( nFamily, SFXSTYLEBIT_ALL );
pStyle = pIter->First();
if (pStyle)
aEffName = pStyle->GetName();
@@ -258,7 +258,7 @@ bool ScStyleSheet::IsUsed() const
{
// Always query the document to let it decide if a rescan is necessary,
// and store the state.
- ScDocument* pDoc = static_cast<ScStyleSheetPool*>(pPool)->GetDocument();
+ ScDocument* pDoc = static_cast<ScStyleSheetPool*>(m_pPool)->GetDocument();
if ( pDoc && pDoc->IsStyleSheetUsed( *this ) )
eUsage = USED;
else
diff --git a/sd/source/core/stlsheet.cxx b/sd/source/core/stlsheet.cxx
index a304bd36f65d..7b5ef91a07fc 100644
--- a/sd/source/core/stlsheet.cxx
+++ b/sd/source/core/stlsheet.cxx
@@ -179,7 +179,7 @@ bool SdStyleSheet::SetParent(const OUString& rParentName)
{
if( !rParentName.isEmpty() )
{
- SfxStyleSheetBase* pStyle = pPool->Find(rParentName, nFamily);
+ SfxStyleSheetBase* pStyle = m_pPool->Find(rParentName, nFamily);
if (pStyle)
{
bResult = true;
@@ -333,7 +333,7 @@ SdStyleSheet* SdStyleSheet::GetRealStyleSheet() const
OUString aRealStyle;
OUString aSep( SD_LT_SEPARATOR );
SdStyleSheet* pRealStyle = nullptr;
- SdDrawDocument* pDoc = static_cast<SdStyleSheetPool*>(pPool)->GetDoc();
+ SdDrawDocument* pDoc = static_cast<SdStyleSheetPool*>(m_pPool)->GetDoc();
::sd::DrawViewShell* pDrawViewShell = nullptr;
@@ -367,7 +367,7 @@ SdStyleSheet* SdStyleSheet::GetRealStyleSheet() const
{
/* no page available yet. This can happen when actualizing the
document templates. */
- SfxStyleSheetIterator aIter(pPool, SfxStyleFamily::Page);
+ SfxStyleSheetIterator aIter(m_pPool, SfxStyleFamily::Page);
SfxStyleSheetBase* pSheet = aIter.First();
if( pSheet )
aRealStyle = pSheet->GetName();
@@ -417,12 +417,12 @@ SdStyleSheet* SdStyleSheet::GetRealStyleSheet() const
}
aRealStyle += aInternalName;
- pRealStyle = static_cast< SdStyleSheet* >( pPool->Find(aRealStyle, SfxStyleFamily::Page) );
+ pRealStyle = static_cast< SdStyleSheet* >( m_pPool->Find(aRealStyle, SfxStyleFamily::Page) );
#ifdef DBG_UTIL
if( !pRealStyle )
{
- SfxStyleSheetIterator aIter(pPool, SfxStyleFamily::Page);
+ SfxStyleSheetIterator aIter(m_pPool, SfxStyleFamily::Page);
if( aIter.Count() > 0 )
// StyleSheet not found, but pool already loaded
DBG_ASSERT(pRealStyle, "Internal StyleSheet not found");
@@ -479,7 +479,7 @@ SdStyleSheet* SdStyleSheet::GetPseudoStyleSheet() const
}
}
- pPseudoStyle = static_cast<SdStyleSheet*>(pPool->Find(aStyleName, SfxStyleFamily::Pseudo));
+ pPseudoStyle = static_cast<SdStyleSheet*>(m_pPool->Find(aStyleName, SfxStyleFamily::Pseudo));
DBG_ASSERT(pPseudoStyle, "PseudoStyleSheet missing");
return pPseudoStyle;
@@ -735,7 +735,7 @@ void SdStyleSheet::disposing()
delete pSet;
}
pSet = nullptr;
- pPool = nullptr;
+ m_pPool = nullptr;
mxPool.clear();
}
diff --git a/svl/source/items/style.cxx b/svl/source/items/style.cxx
index 7cfc727dc655..6ff9e7642297 100644
--- a/svl/source/items/style.cxx
+++ b/svl/source/items/style.cxx
@@ -101,7 +101,7 @@ public:
SfxStyleSheetBase::SfxStyleSheetBase( const OUString& rName, SfxStyleSheetBasePool* p, SfxStyleFamily eFam, sal_uInt16 mask )
- : pPool( p )
+ : m_pPool( p )
, nFamily( eFam )
, aName( rName )
, aParent()
@@ -119,7 +119,7 @@ SfxStyleSheetBase::SfxStyleSheetBase( const OUString& rName, SfxStyleSheetBasePo
SfxStyleSheetBase::SfxStyleSheetBase( const SfxStyleSheetBase& r )
: comphelper::OWeakTypeObject()
- , pPool( r.pPool )
+ , m_pPool( r.m_pPool )
, nFamily( r.nFamily )
, aName( r.aName )
, aParent( r.aParent )
@@ -166,25 +166,25 @@ bool SfxStyleSheetBase::SetName(const OUString& rName, bool bReIndexNow)
if( aName != rName )
{
OUString aOldName = aName;
- SfxStyleSheetBase *pOther = pPool->Find( rName, nFamily ) ;
+ SfxStyleSheetBase *pOther = m_pPool->Find( rName, nFamily ) ;
if ( pOther && pOther != this )
return false;
- SfxStyleFamily eTmpFam = pPool->GetSearchFamily();
- sal_uInt16 nTmpMask = pPool->GetSearchMask();
+ SfxStyleFamily eTmpFam = m_pPool->GetSearchFamily();
+ sal_uInt16 nTmpMask = m_pPool->GetSearchMask();
- pPool->SetSearchMask(nFamily);
+ m_pPool->SetSearchMask(nFamily);
if ( !aName.isEmpty() )
- pPool->ChangeParent( aName, rName, false );
+ m_pPool->ChangeParent( aName, rName, false );
if ( aFollow == aName )
aFollow = rName;
aName = rName;
if (bReIndexNow)
- pPool->Reindex();
- pPool->SetSearchMask(eTmpFam, nTmpMask);
- pPool->Broadcast( SfxStyleSheetModifiedHint( aOldName, *this ) );
+ m_pPool->Reindex();
+ m_pPool->SetSearchMask(eTmpFam, nTmpMask);
+ m_pPool->Broadcast( SfxStyleSheetModifiedHint( aOldName, *this ) );
}
return true;
}
@@ -202,7 +202,7 @@ bool SfxStyleSheetBase::SetParent( const OUString& rName )
if( aParent != rName )
{
- SfxStyleSheetBase* pIter = pPool->Find(rName, nFamily);
+ SfxStyleSheetBase* pIter = m_pPool->Find(rName, nFamily);
if( !rName.isEmpty() && !pIter )
{
OSL_FAIL( "StyleSheet-Parent not found" );
@@ -215,19 +215,19 @@ bool SfxStyleSheetBase::SetParent( const OUString& rName )
{
if(pIter->GetName() == aName)
return false;
- pIter = pPool->Find(pIter->GetParent(), nFamily);
+ pIter = m_pPool->Find(pIter->GetParent(), nFamily);
}
}
aParent = rName;
}
- pPool->Broadcast( SfxStyleSheetHint( SfxHintId::StyleSheetModified, *this ) );
+ m_pPool->Broadcast( SfxStyleSheetHint( SfxHintId::StyleSheetModified, *this ) );
return true;
}
void SfxStyleSheetBase::SetHidden( bool hidden )
{
bHidden = hidden;
- pPool->Broadcast( SfxStyleSheetHint( SfxHintId::StyleSheetModified, *this ) );
+ m_pPool->Broadcast( SfxStyleSheetHint( SfxHintId::StyleSheetModified, *this ) );
}
/**
@@ -242,14 +242,14 @@ bool SfxStyleSheetBase::SetFollow( const OUString& rName )
{
if( aFollow != rName )
{
- if( !pPool->Find( rName, nFamily ) )
+ if( !m_pPool->Find( rName, nFamily ) )
{
SAL_WARN( "svl.items", "StyleSheet-Follow not found" );
return false;
}
aFollow = rName;
}
- pPool->Broadcast( SfxStyleSheetHint( SfxHintId::StyleSheetModified, *this ) );
+ m_pPool->Broadcast( SfxStyleSheetHint( SfxHintId::StyleSheetModified, *this ) );
return true;
}
@@ -261,7 +261,7 @@ SfxItemSet& SfxStyleSheetBase::GetItemSet()
{
if( !pSet )
{
- pSet = new SfxItemSet( pPool->GetPool() );
+ pSet = new SfxItemSet( m_pPool->GetPool() );
bMySet = true;
}
return *pSet;
@@ -337,7 +337,7 @@ OUString SfxStyleSheetBase::GetDescription( MapUnit eMetric )
OUString aItemPresentation;
if ( !IsInvalidItem( pItem ) &&
- pPool->GetPool().GetPresentation(
+ m_pPool->GetPool().GetPresentation(
*pItem, eMetric, aItemPresentation, aIntlWrapper ) )
{
if ( !aDesc.isEmpty() && !aItemPresentation.isEmpty() )
@@ -870,14 +870,14 @@ bool SfxStyleSheet::SetParent( const OUString& rName )
// Remove from notification chain of the old parent if applicable
if(!aOldParent.isEmpty())
{
- SfxStyleSheet *pParent = static_cast<SfxStyleSheet *>(pPool->Find(aOldParent, nFamily));
+ SfxStyleSheet *pParent = static_cast<SfxStyleSheet *>(m_pPool->Find(aOldParent, nFamily));
if(pParent)
EndListening(*pParent);
}
// Add to the notification chain of the new parent
if(!aParent.isEmpty())
{
- SfxStyleSheet *pParent = static_cast<SfxStyleSheet *>(pPool->Find(aParent, nFamily));
+ SfxStyleSheet *pParent = static_cast<SfxStyleSheet *>(m_pPool->Find(aParent, nFamily));
if(pParent)
StartListening(*pParent);
}
diff --git a/sw/source/uibase/app/docstyle.cxx b/sw/source/uibase/app/docstyle.cxx
index 072f79a68edc..fc55b14ecfdb 100644
--- a/sw/source/uibase/app/docstyle.cxx
+++ b/sw/source/uibase/app/docstyle.cxx
@@ -544,8 +544,8 @@ void SwDocStyleSheet::SetGrabBagItem(const uno::Any& rVal)
if (bChg)
{
- dynamic_cast<SwDocStyleSheetPool&>(*pPool).InvalidateIterator();
- pPool->Broadcast(SfxStyleSheetHint(SfxHintId::StyleSheetModified, *this));
+ dynamic_cast<SwDocStyleSheetPool&>(*m_pPool).InvalidateIterator();
+ m_pPool->Broadcast(SfxStyleSheetHint(SfxHintId::StyleSheetModified, *this));
SwEditShell* pSh = rDoc.GetEditShell();
if (pSh)
pSh->CallChgLnk();
@@ -655,8 +655,8 @@ void SwDocStyleSheet::SetHidden( bool bValue )
if( bChg )
{
// calling pPool->First() here would be quite slow...
- dynamic_cast<SwDocStyleSheetPool&>(*pPool).InvalidateIterator(); // internal list has to be updated
- pPool->Broadcast( SfxStyleSheetHint( SfxHintId::StyleSheetModified, *this ) );
+ dynamic_cast<SwDocStyleSheetPool&>(*m_pPool).InvalidateIterator(); // internal list has to be updated
+ m_pPool->Broadcast( SfxStyleSheetHint( SfxHintId::StyleSheetModified, *this ) );
SwEditShell* pSh = rDoc.GetEditShell();
if( pSh )
pSh->CallChgLnk();
@@ -846,7 +846,7 @@ OUString SwDocStyleSheet::GetDescription(MapUnit eUnit)
{
OUString aItemPresentation;
if ( !IsInvalidItem( pItem ) &&
- pPool->GetPool().GetPresentation(
+ m_pPool->GetPool().GetPresentation(
*pItem, eUnit, aItemPresentation, aIntlWrapper ) )
{
if ( !aDesc.isEmpty() && !aItemPresentation.isEmpty() )
@@ -894,7 +894,7 @@ OUString SwDocStyleSheet::GetDescription(MapUnit eUnit)
{
OUString aItemPresentation;
if ( !IsInvalidItem( pItem ) &&
- pPool->GetPool().GetPresentation(
+ m_pPool->GetPool().GetPresentation(
*pItem, eUnit, aItemPresentation, aIntlWrapper ) )
{
bool bIsDefault = false;
@@ -1141,8 +1141,8 @@ bool SwDocStyleSheet::SetName(const OUString& rStr, bool bReindexNow)
if( bChg )
{
- pPool->First(); // internal list has to be updated
- pPool->Broadcast( SfxStyleSheetHint( SfxHintId::StyleSheetModified, *this ) );
+ m_pPool->First(); // internal list has to be updated
+ m_pPool->Broadcast( SfxStyleSheetHint( SfxHintId::StyleSheetModified, *this ) );
SwEditShell* pSh = rDoc.GetEditShell();
if( pSh )
pSh->CallChgLnk();
@@ -1193,7 +1193,7 @@ bool SwDocStyleSheet::SetParent( const OUString& rStr)
if( bRet )
{
aParent = rStr;
- pPool->Broadcast( SfxStyleSheetHint( SfxHintId::StyleSheetModified,
+ m_pPool->Broadcast( SfxStyleSheetHint( SfxHintId::StyleSheetModified,
*this ) );
}
}
More information about the Libreoffice-commits
mailing list