Kaydet (Commit) 850bfeed authored tarafından Noel Grandin's avatar Noel Grandin Kaydeden (comit) Michael Stahl

Convert SV_DECL_PTRARR to std::vector

üst 96a36b91
...@@ -1085,8 +1085,7 @@ SvxXMLListLevelStyleLabelAlignmentAttrContext_Impl::~SvxXMLListLevelStyleLabelAl ...@@ -1085,8 +1085,7 @@ SvxXMLListLevelStyleLabelAlignmentAttrContext_Impl::~SvxXMLListLevelStyleLabelAl
// --------------------------------------------------------------------- // ---------------------------------------------------------------------
typedef SvxXMLListLevelStyleContext_Impl *SvxXMLListLevelStyleContext_ImplPtr; class SvxXMLListStyle_Impl : public std::vector<SvxXMLListLevelStyleContext_Impl *> {};
SV_DECL_PTRARR( SvxXMLListStyle_Impl, SvxXMLListLevelStyleContext_ImplPtr, 10 )
void SvxXMLListStyleContext::SetAttribute( sal_uInt16 nPrefixKey, void SvxXMLListStyleContext::SetAttribute( sal_uInt16 nPrefixKey,
const OUString& rLocalName, const OUString& rLocalName,
...@@ -1125,11 +1124,10 @@ SvxXMLListStyleContext::~SvxXMLListStyleContext() ...@@ -1125,11 +1124,10 @@ SvxXMLListStyleContext::~SvxXMLListStyleContext()
{ {
if( pLevelStyles ) if( pLevelStyles )
{ {
while( pLevelStyles->Count() ) while( !pLevelStyles->empty() )
{ {
sal_uInt16 n = pLevelStyles->Count() - 1; SvxXMLListLevelStyleContext_Impl *pStyle = pLevelStyles->back();
SvxXMLListLevelStyleContext_Impl *pStyle = (*pLevelStyles)[n]; pLevelStyles->pop_back();
pLevelStyles->Remove( n, 1 );
pStyle->ReleaseRef(); pStyle->ReleaseRef();
} }
} }
...@@ -1158,7 +1156,7 @@ SvXMLImportContext *SvxXMLListStyleContext::CreateChildContext( ...@@ -1158,7 +1156,7 @@ SvXMLImportContext *SvxXMLListStyleContext::CreateChildContext(
rLocalName, xAttrList ); rLocalName, xAttrList );
if( !pLevelStyles ) if( !pLevelStyles )
pLevelStyles = new SvxXMLListStyle_Impl; pLevelStyles = new SvxXMLListStyle_Impl;
pLevelStyles->Insert( pLevelStyle, pLevelStyles->Count() ); pLevelStyles->push_back( pLevelStyle );
pLevelStyle->AddRef(); pLevelStyle->AddRef();
pContext = pLevelStyle; pContext = pLevelStyle;
...@@ -1179,7 +1177,7 @@ void SvxXMLListStyleContext::FillUnoNumRule( ...@@ -1179,7 +1177,7 @@ void SvxXMLListStyleContext::FillUnoNumRule(
{ {
if( pLevelStyles && rNumRule.is() ) if( pLevelStyles && rNumRule.is() )
{ {
sal_uInt16 nCount = pLevelStyles->Count(); sal_uInt16 nCount = pLevelStyles->size();
sal_Int32 l_nLevels = rNumRule->getCount(); sal_Int32 l_nLevels = rNumRule->getCount();
for( sal_uInt16 i=0; i < nCount; i++ ) for( sal_uInt16 i=0; i < nCount; i++ )
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment