Kaydet (Commit) 25e92d7f authored tarafından Noel Grandin's avatar Noel Grandin

loplugin:inlinefields in XMLTextParagraphExport

Change-Id: If0e80fbe21b6d8bed55357d7fc09027fc4a37e06
Reviewed-on: https://gerrit.libreoffice.org/36373Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarNoel Grandin <noel.grandin@collabora.co.uk>
üst 3df73dc9
...@@ -29,6 +29,7 @@ ...@@ -29,6 +29,7 @@
#include <xmloff/styleexp.hxx> #include <xmloff/styleexp.hxx>
#include <xmloff/xmltoken.hxx> #include <xmloff/xmltoken.hxx>
#include <xmloff/SinglePropertySetInfoCache.hxx> #include <xmloff/SinglePropertySetInfoCache.hxx>
#include <xmloff/XMLTextListAutoStylePool.hxx>
#include <memory> #include <memory>
#include <vector> #include <vector>
...@@ -86,7 +87,7 @@ class XMLOFF_DLLPUBLIC XMLTextParagraphExport : public XMLStyleExport ...@@ -86,7 +87,7 @@ class XMLOFF_DLLPUBLIC XMLTextParagraphExport : public XMLStyleExport
const ::std::unique_ptr< ::xmloff::BoundFrameSets > pBoundFrameSets; const ::std::unique_ptr< ::xmloff::BoundFrameSets > pBoundFrameSets;
XMLTextFieldExport *pFieldExport; XMLTextFieldExport *pFieldExport;
std::vector<OUString> *pListElements; std::vector<OUString> *pListElements;
XMLTextListAutoStylePool *pListAutoPool; XMLTextListAutoStylePool maListAutoPool;
XMLSectionExport *pSectionExport; XMLSectionExport *pSectionExport;
XMLIndexMarkExport *pIndexMarkExport; XMLIndexMarkExport *pIndexMarkExport;
...@@ -587,7 +588,7 @@ private: ...@@ -587,7 +588,7 @@ private:
inline const XMLTextListAutoStylePool& inline const XMLTextListAutoStylePool&
XMLTextParagraphExport::GetListAutoStylePool() const XMLTextParagraphExport::GetListAutoStylePool() const
{ {
return *pListAutoPool; return maListAutoPool;
} }
inline void XMLTextParagraphExport::exportTextFrame( inline void XMLTextParagraphExport::exportTextFrame(
......
...@@ -531,7 +531,7 @@ void XMLTextParagraphExport::Add( sal_uInt16 nFamily, ...@@ -531,7 +531,7 @@ void XMLTextParagraphExport::Add( sal_uInt16 nFamily,
} }
} }
if( bAdd ) if( bAdd )
pListAutoPool->Add( xNumRule ); maListAutoPool.Add( xNumRule );
} }
} }
break; break;
...@@ -637,7 +637,7 @@ void XMLTextParagraphExport::Add( sal_uInt16 nFamily, ...@@ -637,7 +637,7 @@ void XMLTextParagraphExport::Add( sal_uInt16 nFamily,
} }
} }
if( bAdd ) if( bAdd )
pListAutoPool->Add( xNumRule ); maListAutoPool.Add( xNumRule );
} }
} }
...@@ -1161,7 +1161,7 @@ XMLTextParagraphExport::XMLTextParagraphExport( ...@@ -1161,7 +1161,7 @@ XMLTextParagraphExport::XMLTextParagraphExport(
pBoundFrameSets(new BoundFrameSets(GetExport().GetModel())), pBoundFrameSets(new BoundFrameSets(GetExport().GetModel())),
pFieldExport( nullptr ), pFieldExport( nullptr ),
pListElements( nullptr ), pListElements( nullptr ),
pListAutoPool( new XMLTextListAutoStylePool( this->GetExport() ) ), maListAutoPool( this->GetExport() ),
pSectionExport( nullptr ), pSectionExport( nullptr ),
pIndexMarkExport( nullptr ), pIndexMarkExport( nullptr ),
pRedlineExport( nullptr ), pRedlineExport( nullptr ),
...@@ -1320,7 +1320,6 @@ XMLTextParagraphExport::~XMLTextParagraphExport() ...@@ -1320,7 +1320,6 @@ XMLTextParagraphExport::~XMLTextParagraphExport()
delete pSectionExport; delete pSectionExport;
delete pFieldExport; delete pFieldExport;
delete pListElements; delete pListElements;
delete pListAutoPool;
#ifdef DBG_UTIL #ifdef DBG_UTIL
txtparae_bContainsIllegalCharacters = false; txtparae_bContainsIllegalCharacters = false;
#endif #endif
...@@ -1624,7 +1623,7 @@ bool XMLTextParagraphExport::collectTextAutoStylesOptimized( bool bIsProgress ) ...@@ -1624,7 +1623,7 @@ bool XMLTextParagraphExport::collectTextAutoStylesOptimized( bool bIsProgress )
} }
} }
if( bAdd ) if( bAdd )
pListAutoPool->Add( xNumRule ); maListAutoPool.Add( xNumRule );
} }
} }
} }
...@@ -3617,7 +3616,7 @@ void XMLTextParagraphExport::exportTextAutoStyles() ...@@ -3617,7 +3616,7 @@ void XMLTextParagraphExport::exportTextAutoStyles()
GetExport().GetMM100UnitConverter(), GetExport().GetMM100UnitConverter(),
GetExport().GetNamespaceMap() ); GetExport().GetNamespaceMap() );
pListAutoPool->exportXML(); maListAutoPool.exportXML();
} }
void XMLTextParagraphExport::exportRuby( void XMLTextParagraphExport::exportRuby(
......
...@@ -105,7 +105,7 @@ void XMLTextParagraphExport::exportStyleAttributes( ...@@ -105,7 +105,7 @@ void XMLTextParagraphExport::exportStyleAttributes(
void XMLTextParagraphExport::exportNumStyles( bool bUsed ) void XMLTextParagraphExport::exportNumStyles( bool bUsed )
{ {
SvxXMLNumRuleExport aNumRuleExport( GetExport() ); SvxXMLNumRuleExport aNumRuleExport( GetExport() );
aNumRuleExport.exportStyles( bUsed, pListAutoPool, !IsBlockMode() ); aNumRuleExport.exportStyles( bUsed, &maListAutoPool, !IsBlockMode() );
} }
void XMLTextParagraphExport::exportTextStyles( bool bUsed, bool bProg ) void XMLTextParagraphExport::exportTextStyles( bool bUsed, bool bProg )
......
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