diff options
author | Noel Grandin <noel@peralex.com> | 2012-07-13 15:23:15 +0200 |
---|---|---|
committer | Michael Stahl <mstahl@redhat.com> | 2012-07-17 15:33:37 +0200 |
commit | 22faf8438f01d67fe3381aa353e5187f36ce4098 (patch) | |
tree | f5391f972ec104b1f62ca4c31db6e06e6c7f2dc7 /sw | |
parent | fix previous STL conversion commit: (diff) | |
download | core-22faf8438f01d67fe3381aa353e5187f36ce4098.tar.gz core-22faf8438f01d67fe3381aa353e5187f36ce4098.zip |
Convert SV_DECL_PTRARR_SORT(SwpFmts) to std::set
Change-Id: Ia5bbf4960cae0b2e4a975ded067d46a85a0b3ab9
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/core/crsr/findattr.cxx | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/sw/source/core/crsr/findattr.cxx b/sw/source/core/crsr/findattr.cxx index 26cd65669103..0081079cdbbc 100644 --- a/sw/source/core/crsr/findattr.cxx +++ b/sw/source/core/crsr/findattr.cxx @@ -55,8 +55,7 @@ using namespace ::com::sun::star; using namespace ::com::sun::star::lang; using namespace ::com::sun::star::util; -SV_DECL_PTRARR_SORT( SwpFmts, SwFmt*, 0 ) -SV_IMPL_PTRARR_SORT( SwpFmts, SwFmt* ) +typedef std::set<SwFmt*> SwpFmts; // Sonderbehandlung fuer SvxFontItem, nur den Namen vergleichen: int CmpAttr( const SfxPoolItem& rItem1, const SfxPoolItem& rItem2 ) @@ -920,10 +919,10 @@ sal_Bool SwPaM::Find( const SfxPoolItem& rAttr, sal_Bool bValue, SwMoveFn fnMove // no hard attribution, so check if node was asked for this attr before if( !pNode->HasSwAttrSet() ) { - const SwFmt* pTmpFmt = pNode->GetFmtColl(); - if( aFmtArr.Count() && aFmtArr.Seek_Entry( pTmpFmt )) + SwFmt* pTmpFmt = pNode->GetFmtColl(); + if( aFmtArr.find( pTmpFmt ) != aFmtArr.end() ) continue; // collection was requested earlier - aFmtArr.Insert( pTmpFmt ); + aFmtArr.insert( pTmpFmt ); } if( SFX_ITEM_SET == pNode->GetSwAttrSet().GetItemState( nWhich, @@ -1016,10 +1015,10 @@ sal_Bool SwPaM::Find( const SfxItemSet& rSet, sal_Bool bNoColls, SwMoveFn fnMove // no hard attribution, so check if node was asked for this attr before if( !pNode->HasSwAttrSet() ) { - const SwFmt* pTmpFmt = pNode->GetFmtColl(); - if( aFmtArr.Count() && aFmtArr.Seek_Entry( pTmpFmt )) + SwFmt* pTmpFmt = pNode->GetFmtColl(); + if( aFmtArr.find( pTmpFmt ) != aFmtArr.end() ) continue; // collection was requested earlier - aFmtArr.Insert( pTmpFmt ); + aFmtArr.insert( pTmpFmt ); } if( lcl_Search( *pNode, aOtherSet, bNoColls )) |