dbaccess/source/filter/xml/xmlExport.cxx     |    7 +--
 include/xmloff/xmlaustp.hxx                  |    8 ++--
 reportdesign/source/filter/xml/xmlExport.cxx |   16 +++-----
 sc/source/filter/xml/xmlexprt.cxx            |   32 ++++++++--------
 xmloff/qa/unit/uxmloff.cxx                   |    5 +-
 xmloff/source/chart/SchXMLChartContext.cxx   |    4 --
 xmloff/source/chart/SchXMLExport.cxx         |   52 +++++++++++++--------------
 xmloff/source/core/RDFaImportHelper.cxx      |    8 ++--
 xmloff/source/draw/sdxmlexp.cxx              |    2 -
 xmloff/source/draw/shapeexport.cxx           |    4 +-
 xmloff/source/forms/layerexport.cxx          |    2 -
 xmloff/source/style/XMLPageExport.cxx        |    6 +--
 xmloff/source/style/impastpl.cxx             |   20 +++++-----
 xmloff/source/style/impastpl.hxx             |   10 ++---
 xmloff/source/style/xmlaustp.cxx             |   16 ++++----
 xmloff/source/table/XMLTableExport.cxx       |    6 +--
 xmloff/source/text/txtparae.cxx              |    8 ++--
 17 files changed, 100 insertions(+), 106 deletions(-)

New commits:
commit f67392948d625db9ce115092e4c9bfd301268a25
Author:     Noel Grandin <[email protected]>
AuthorDate: Sun Oct 10 19:59:23 2021 +0200
Commit:     Noel Grandin <[email protected]>
CommitDate: Sun Oct 10 21:03:18 2021 +0200

    loplugin:moveparam in xmloff
    
    Change-Id: I46c1c8dc46cd2b8470b69506f6609f8bd7e42211
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123347
    Tested-by: Jenkins
    Reviewed-by: Noel Grandin <[email protected]>

diff --git a/dbaccess/source/filter/xml/xmlExport.cxx 
b/dbaccess/source/filter/xml/xmlExport.cxx
index 1e4f79d4ce44..e0c1304c8cc6 100644
--- a/dbaccess/source/filter/xml/xmlExport.cxx
+++ b/dbaccess/source/filter/xml/xmlExport.cxx
@@ -1071,12 +1071,11 @@ void ODBExport::exportAutoStyle(XPropertySet* _xProp)
             
,TExportPropMapperPair(m_xRowExportHelper,TEnumMapperPair(&m_aRowAutoStyleNames,XmlStyleFamily::TABLE_ROW))
         };
 
-        std::vector< XMLPropertyState > aPropertyStates;
         for (const auto & i : pExportHelper)
         {
-            aPropertyStates = i.first->Filter(*this, _xProp);
+            std::vector< XMLPropertyState > aPropertyStates = 
i.first->Filter(*this, _xProp);
             if ( !aPropertyStates.empty() )
-                i.second.first->emplace( _xProp,GetAutoStylePool()->Add( 
i.second.second, aPropertyStates ) );
+                i.second.first->emplace( _xProp,GetAutoStylePool()->Add( 
i.second.second, std::move(aPropertyStates) ) );
         }
 
         Reference< XNameAccess > xCollection;
@@ -1148,7 +1147,7 @@ void ODBExport::exportAutoStyle(XPropertySet* _xProp)
             if ( XmlStyleFamily::TABLE_CELL == i.second.second )
                 aPropStates.insert( aPropStates.end(), 
m_aCurrentPropertyStates.begin(), m_aCurrentPropertyStates.end() );
             if ( !aPropStates.empty() )
-                i.second.first->emplace( _xProp,GetAutoStylePool()->Add( 
i.second.second, aPropStates ) );
+                i.second.first->emplace( _xProp,GetAutoStylePool()->Add( 
i.second.second, std::move(aPropStates) ) );
         }
     }
 }
diff --git a/include/xmloff/xmlaustp.hxx b/include/xmloff/xmlaustp.hxx
index ed389d9530bb..1adc3b786a91 100644
--- a/include/xmloff/xmlaustp.hxx
+++ b/include/xmloff/xmlaustp.hxx
@@ -111,13 +111,13 @@ public:
         css::uno::Sequence<OUString> const & aNames );
 
     /// Add an item set to the pool and return its generated name.
-    OUString Add( XmlStyleFamily nFamily, const ::std::vector< 
XMLPropertyState >& rProperties );
-    OUString Add( XmlStyleFamily nFamily, const OUString& rParent, const 
::std::vector< XMLPropertyState >& rProperties, bool bDontSeek = false );
-    bool        Add( OUString& rName, XmlStyleFamily nFamily, const OUString& 
rParent, const ::std::vector< XMLPropertyState >& rProperties );
+    OUString Add( XmlStyleFamily nFamily, ::std::vector< XMLPropertyState >&& 
rProperties );
+    OUString Add( XmlStyleFamily nFamily, const OUString& rParent, 
::std::vector< XMLPropertyState >&& rProperties, bool bDontSeek = false );
+    bool        Add( OUString& rName, XmlStyleFamily nFamily, const OUString& 
rParent, ::std::vector< XMLPropertyState >&& rProperties );
 
     /// Add an item set with a pre-defined name (needed for saving sheets 
separately in Calc).
     bool        AddNamed( const OUString& rName, XmlStyleFamily nFamily, const 
OUString& rParent,
-                              const ::std::vector< XMLPropertyState >& 
rProperties );
+                              std::vector< XMLPropertyState >&& rProperties );
 
     /// Find an item set's name.
     OUString Find( XmlStyleFamily nFamily, const OUString& rParent, const 
::std::vector< XMLPropertyState >& rProperties ) const;
diff --git a/reportdesign/source/filter/xml/xmlExport.cxx 
b/reportdesign/source/filter/xml/xmlExport.cxx
index 7968a237ac7c..d9a673e81250 100644
--- a/reportdesign/source/filter/xml/xmlExport.cxx
+++ b/reportdesign/source/filter/xml/xmlExport.cxx
@@ -453,28 +453,26 @@ static void lcl_calculate(const ::std::vector<sal_Int32>& 
_aPosX,const ::std::ve
 
 void ORptExport::collectStyleNames(XmlStyleFamily _nFamily,const 
::std::vector< sal_Int32>& _aSize, std::vector<OUString>& _rStyleNames)
 {
-    ::std::vector< XMLPropertyState > aPropertyStates;
-    aPropertyStates.emplace_back(0);
     ::std::vector<sal_Int32>::const_iterator aIter = _aSize.begin();
     ::std::vector<sal_Int32>::const_iterator aIter2 = aIter + 1;
     ::std::vector<sal_Int32>::const_iterator aEnd = _aSize.end();
     for (;aIter2 != aEnd ; ++aIter,++aIter2)
     {
+        ::std::vector< XMLPropertyState > aPropertyStates(1, 0);
         sal_Int32 nValue = static_cast<sal_Int32>(*aIter2 - *aIter);
         aPropertyStates[0].maValue <<= nValue;
-        _rStyleNames.push_back(GetAutoStylePool()->Add(_nFamily, 
aPropertyStates ));
+        _rStyleNames.push_back(GetAutoStylePool()->Add(_nFamily, 
std::move(aPropertyStates) ));
     }
 }
 
 void ORptExport::collectStyleNames(XmlStyleFamily _nFamily, const 
::std::vector< sal_Int32>& _aSize, const ::std::vector< sal_Int32>& 
_aSizeAutoGrow, std::vector<OUString>& _rStyleNames)
 {
-    ::std::vector< XMLPropertyState > aPropertyStates;
-    aPropertyStates.emplace_back(0);
     ::std::vector<sal_Int32>::const_iterator aIter = _aSize.begin();
     ::std::vector<sal_Int32>::const_iterator aIter2 = aIter + 1;
     ::std::vector<sal_Int32>::const_iterator aEnd = _aSize.end();
     for (;aIter2 != aEnd; ++aIter, ++aIter2)
     {
+        ::std::vector< XMLPropertyState > aPropertyStates(1, 0);
         sal_Int32 nValue = static_cast<sal_Int32>(*aIter2 - *aIter);
         aPropertyStates[0].maValue <<= nValue;
         // note: there cannot be 0-height rows, because a call to std::unique 
has removed them
@@ -485,7 +483,7 @@ void ORptExport::collectStyleNames(XmlStyleFamily _nFamily, 
const ::std::vector<
         bool bAutoGrow = aAutoGrow != _aSizeAutoGrow.end();
         // the mnIndex is into the array returned by 
OXMLHelper::GetRowStyleProps()
         aPropertyStates[0].mnIndex = bAutoGrow ? 1 : 0;
-        _rStyleNames.push_back(GetAutoStylePool()->Add(_nFamily, 
aPropertyStates));
+        _rStyleNames.push_back(GetAutoStylePool()->Add(_nFamily, 
std::move(aPropertyStates)));
     }
 }
 
@@ -1114,7 +1112,7 @@ void ORptExport::exportAutoStyle(XPropertySet* 
_xProp,const Reference<XFormatted
     {
         ::std::vector<XMLPropertyState> 
aPropertyStates(m_xParaPropMapper->Filter(*this, _xProp));
         if ( !aPropertyStates.empty() )
-            m_aAutoStyleNames.emplace( _xProp,GetAutoStylePool()->Add( 
XmlStyleFamily::TEXT_PARAGRAPH, aPropertyStates ));
+            m_aAutoStyleNames.emplace( _xProp,GetAutoStylePool()->Add( 
XmlStyleFamily::TEXT_PARAGRAPH, std::move(aPropertyStates) ));
     }
     ::std::vector<XMLPropertyState> 
aPropertyStates(m_xCellStylesExportPropertySetMapper->Filter(*this, _xProp));
     Reference<XFixedLine> xFixedLine(_xProp,uno::UNO_QUERY);
@@ -1214,14 +1212,14 @@ void ORptExport::exportAutoStyle(XPropertySet* 
_xProp,const Reference<XFormatted
     }
 
     if ( !aPropertyStates.empty() )
-        m_aAutoStyleNames.emplace( _xProp,GetAutoStylePool()->Add( 
XmlStyleFamily::TABLE_CELL, aPropertyStates ));
+        m_aAutoStyleNames.emplace( _xProp,GetAutoStylePool()->Add( 
XmlStyleFamily::TABLE_CELL, std::move(aPropertyStates) ));
 }
 
 void ORptExport::exportAutoStyle(const Reference<XSection>& _xProp)
 {
     ::std::vector<XMLPropertyState> 
aPropertyStates(m_xTableStylesExportPropertySetMapper->Filter(*this, _xProp));
     if ( !aPropertyStates.empty() )
-        m_aAutoStyleNames.emplace( _xProp.get(),GetAutoStylePool()->Add( 
XmlStyleFamily::TABLE_TABLE, aPropertyStates ));
+        m_aAutoStyleNames.emplace( _xProp.get(),GetAutoStylePool()->Add( 
XmlStyleFamily::TABLE_TABLE, std::move(aPropertyStates) ));
 }
 
 void ORptExport::SetBodyAttributes()
diff --git a/sc/source/filter/xml/xmlexprt.cxx 
b/sc/source/filter/xml/xmlexprt.cxx
index 1cf9ec4fdc37..1de7927c9634 100644
--- a/sc/source/filter/xml/xmlexprt.cxx
+++ b/sc/source/filter/xml/xmlexprt.cxx
@@ -909,7 +909,7 @@ void ScXMLExport::ExportExternalRefCacheStyles()
 
         OUString aName;
         sal_Int32 nIndex;
-        if (GetAutoStylePool()->Add(aName, XmlStyleFamily::TABLE_CELL, 
aDefaultStyle, aProps))
+        if (GetAutoStylePool()->Add(aName, XmlStyleFamily::TABLE_CELL, 
aDefaultStyle, std::move(aProps)))
         {
             pCellStyles->AddStyleName(aName, nIndex);
         }
@@ -1270,7 +1270,7 @@ void ScXMLExport::ExportCellTextAutoStyles(sal_Int32 
nTable)
             std::vector<XMLPropertyState> aPropStates;
             toXMLPropertyStates(aPropStates, rSecAttrs, xMapper, rAttrMap);
             if (!aPropStates.empty())
-                xStylePool->Add(XmlStyleFamily::TEXT_TEXT, OUString(), 
aPropStates);
+                xStylePool->Add(XmlStyleFamily::TEXT_TEXT, OUString(), 
std::move(aPropStates));
         }
     }
 
@@ -2064,7 +2064,7 @@ void ScXMLExport::AddStyleFromCells(const 
uno::Reference<beans::XPropertySet>& x
         sal_Int32 nIndex;
         if (pOldName)
         {
-            if (GetAutoStylePool()->AddNamed(*pOldName, 
XmlStyleFamily::TABLE_CELL, sStyleName, aPropStates))
+            if (GetAutoStylePool()->AddNamed(*pOldName, 
XmlStyleFamily::TABLE_CELL, sStyleName, std::move(aPropStates)))
             {
                 GetAutoStylePool()->RegisterName(XmlStyleFamily::TABLE_CELL, 
*pOldName);
                 // add to pCellStyles, so the name is found for normal sheets
@@ -2083,13 +2083,13 @@ void ScXMLExport::AddStyleFromCells(const 
uno::Reference<beans::XPropertySet>& x
                 if (itr != pFormatData->maIDToName.end())
                 {
                     sName = itr->second;
-                    bAdded = GetAutoStylePool()->AddNamed(sName, 
XmlStyleFamily::TABLE_CELL, sStyleName, aPropStates);
+                    bAdded = GetAutoStylePool()->AddNamed(sName, 
XmlStyleFamily::TABLE_CELL, sStyleName, std::move(aPropStates));
                     if (bAdded)
                         
GetAutoStylePool()->RegisterName(XmlStyleFamily::TABLE_CELL, sName);
                 }
             }
             bool bIsAutoStyle(true);
-            if (bAdded || GetAutoStylePool()->Add(sName, 
XmlStyleFamily::TABLE_CELL, sStyleName, aPropStates))
+            if (bAdded || GetAutoStylePool()->Add(sName, 
XmlStyleFamily::TABLE_CELL, sStyleName, std::move(aPropStates)))
             {
                 pCellStyles->AddStyleName(sName, nIndex);
             }
@@ -2150,7 +2150,7 @@ void ScXMLExport::AddStyleFromColumn(const 
uno::Reference<beans::XPropertySet>&
     const OUString sParent;
     if (pOldName)
     {
-        if (GetAutoStylePool()->AddNamed(*pOldName, 
XmlStyleFamily::TABLE_COLUMN, sParent, aPropStates))
+        if (GetAutoStylePool()->AddNamed(*pOldName, 
XmlStyleFamily::TABLE_COLUMN, sParent, std::move(aPropStates)))
         {
             GetAutoStylePool()->RegisterName(XmlStyleFamily::TABLE_COLUMN, 
*pOldName);
             // add to pColumnStyles, so the name is found for normal sheets
@@ -2160,7 +2160,7 @@ void ScXMLExport::AddStyleFromColumn(const 
uno::Reference<beans::XPropertySet>&
     else
     {
         OUString sName;
-        if (GetAutoStylePool()->Add(sName, XmlStyleFamily::TABLE_COLUMN, 
sParent, aPropStates))
+        if (GetAutoStylePool()->Add(sName, XmlStyleFamily::TABLE_COLUMN, 
sParent, std::move(aPropStates)))
         {
             rIndex = pColumnStyles->AddStyleName(sName);
         }
@@ -2179,7 +2179,7 @@ void ScXMLExport::AddStyleFromRow(const 
uno::Reference<beans::XPropertySet>& xRo
     const OUString sParent;
     if (pOldName)
     {
-        if (GetAutoStylePool()->AddNamed(*pOldName, XmlStyleFamily::TABLE_ROW, 
sParent, aPropStates))
+        if (GetAutoStylePool()->AddNamed(*pOldName, XmlStyleFamily::TABLE_ROW, 
sParent, std::move(aPropStates)))
         {
             GetAutoStylePool()->RegisterName(XmlStyleFamily::TABLE_ROW, 
*pOldName);
             // add to pRowStyles, so the name is found for normal sheets
@@ -2189,7 +2189,7 @@ void ScXMLExport::AddStyleFromRow(const 
uno::Reference<beans::XPropertySet>& xRo
     else
     {
         OUString sName;
-        if (GetAutoStylePool()->Add(sName, XmlStyleFamily::TABLE_ROW, sParent, 
aPropStates))
+        if (GetAutoStylePool()->Add(sName, XmlStyleFamily::TABLE_ROW, sParent, 
std::move(aPropStates)))
         {
             rIndex = pRowStyles->AddStyleName(sName);
         }
@@ -2322,7 +2322,7 @@ void ScXMLExport::collectAutoStyles()
                     {
                         std::vector<XMLPropertyState> 
aPropStates(xTableStylesExportPropertySetMapper->Filter(*this, 
xTableProperties));
                         OUString sName( rTableEntry.maName );
-                        GetAutoStylePool()->AddNamed(sName, 
XmlStyleFamily::TABLE_TABLE, OUString(), aPropStates);
+                        GetAutoStylePool()->AddNamed(sName, 
XmlStyleFamily::TABLE_TABLE, OUString(), std::move(aPropStates));
                         
GetAutoStylePool()->RegisterName(XmlStyleFamily::TABLE_TABLE, sName);
                     }
                 }
@@ -2356,7 +2356,7 @@ void ScXMLExport::collectAutoStyles()
                             {
                                 std::vector<XMLPropertyState> 
aPropStates(xShapeMapper->Filter(*this, xShapeProperties));
                                 OUString sName( rNoteEntry.maStyleName );
-                                GetAutoStylePool()->AddNamed(sName, 
XmlStyleFamily::SD_GRAPHICS_ID, OUString(), aPropStates);
+                                GetAutoStylePool()->AddNamed(sName, 
XmlStyleFamily::SD_GRAPHICS_ID, OUString(), std::move(aPropStates));
                                 
GetAutoStylePool()->RegisterName(XmlStyleFamily::SD_GRAPHICS_ID, sName);
                             }
                             if ( !rNoteEntry.maTextStyle.isEmpty() )
@@ -2364,7 +2364,7 @@ void ScXMLExport::collectAutoStyles()
                                 std::vector<XMLPropertyState> aPropStates(
                                     
GetTextParagraphExport()->GetParagraphPropertyMapper()->Filter(*this, 
xShapeProperties));
                                 OUString sName( rNoteEntry.maTextStyle );
-                                GetAutoStylePool()->AddNamed(sName, 
XmlStyleFamily::TEXT_PARAGRAPH, OUString(), aPropStates);
+                                GetAutoStylePool()->AddNamed(sName, 
XmlStyleFamily::TEXT_PARAGRAPH, OUString(), std::move(aPropStates));
                                 
GetAutoStylePool()->RegisterName(XmlStyleFamily::TEXT_PARAGRAPH, sName);
                             }
                         }
@@ -2396,7 +2396,7 @@ void ScXMLExport::collectAutoStyles()
                         {
                             std::vector<XMLPropertyState> 
aPropStates(xParaPropMapper->Filter(*this, xParaProp));
                             OUString sName( rNoteParaEntry.maName );
-                            GetAutoStylePool()->AddNamed(sName, 
XmlStyleFamily::TEXT_PARAGRAPH, OUString(), aPropStates);
+                            GetAutoStylePool()->AddNamed(sName, 
XmlStyleFamily::TEXT_PARAGRAPH, OUString(), std::move(aPropStates));
                             
GetAutoStylePool()->RegisterName(XmlStyleFamily::TEXT_PARAGRAPH, sName);
                         }
                     }
@@ -2429,7 +2429,7 @@ void ScXMLExport::collectAutoStyles()
 
                             std::vector<XMLPropertyState> 
aPropStates(xTextPropMapper->Filter(*this, xCursorProp));
                             OUString sName( rNoteTextEntry.maName );
-                            GetAutoStylePool()->AddNamed(sName, 
XmlStyleFamily::TEXT_TEXT, OUString(), aPropStates);
+                            GetAutoStylePool()->AddNamed(sName, 
XmlStyleFamily::TEXT_TEXT, OUString(), std::move(aPropStates));
                             
GetAutoStylePool()->RegisterName(XmlStyleFamily::TEXT_TEXT, sName);
                         }
                     }
@@ -2470,7 +2470,7 @@ void ScXMLExport::collectAutoStyles()
 
                 std::vector<XMLPropertyState> 
aPropStates(xTextPropMapper->Filter(*this, xCursorProp));
                 OUString sName( rTextEntry.maName );
-                GetAutoStylePool()->AddNamed(sName, XmlStyleFamily::TEXT_TEXT, 
OUString(), aPropStates);
+                GetAutoStylePool()->AddNamed(sName, XmlStyleFamily::TEXT_TEXT, 
OUString(), std::move(aPropStates));
                 GetAutoStylePool()->RegisterName(XmlStyleFamily::TEXT_TEXT, 
sName);
                 xPrevCursorProp = xCursorProp;
                 aPrevPos = aPos;
@@ -2502,7 +2502,7 @@ void ScXMLExport::collectAutoStyles()
                 if(!aPropStates.empty())
                 {
                     OUString sName;
-                    GetAutoStylePool()->Add(sName, 
XmlStyleFamily::TABLE_TABLE, OUString(), aPropStates);
+                    GetAutoStylePool()->Add(sName, 
XmlStyleFamily::TABLE_TABLE, OUString(), std::move(aPropStates));
                     aTableStyles.push_back(sName);
                 }
             }
diff --git a/xmloff/qa/unit/uxmloff.cxx b/xmloff/qa/unit/uxmloff.cxx
index 1efd05dacafe..867fcd329823 100644
--- a/xmloff/qa/unit/uxmloff.cxx
+++ b/xmloff/qa/unit/uxmloff.cxx
@@ -80,8 +80,7 @@ void Test::testAutoStylePool()
                       xExportPropMapper.get(),
                       OUString( "Bob" ) );
 
-    std::vector< XMLPropertyState > aProperties;
-    OUString aName = xPool->Add( XmlStyleFamily::TEXT_PARAGRAPH, "", 
aProperties );
+    OUString aName = xPool->Add( XmlStyleFamily::TEXT_PARAGRAPH, "", {} );
 
     // not that interesting but worth checking
     bool bHack = (getenv("LIBO_ONEWAY_STABLE_ODF_EXPORT") != nullptr);
@@ -91,7 +90,7 @@ void Test::testAutoStylePool()
         CPPUNIT_ASSERT_EQUAL_MESSAGE( "style / naming changed", 
OUString("Bob1"), aName );
 
     // find ourselves again:
-    OUString aSameName = xPool->Find( XmlStyleFamily::TEXT_PARAGRAPH, "", 
aProperties );
+    OUString aSameName = xPool->Find( XmlStyleFamily::TEXT_PARAGRAPH, "", {} );
     CPPUNIT_ASSERT_EQUAL_MESSAGE( "same style not found", aName, aSameName );
 }
 
diff --git a/xmloff/source/chart/SchXMLChartContext.cxx 
b/xmloff/source/chart/SchXMLChartContext.cxx
index 9c97c64a5a29..54a2879d4f2d 100644
--- a/xmloff/source/chart/SchXMLChartContext.cxx
+++ b/xmloff/source/chart/SchXMLChartContext.cxx
@@ -496,12 +496,10 @@ struct NewDonutSeries
 };
 
 void lcl_swapPointAndSeriesStylesForDonutCharts( ::std::vector< 
DataRowPointStyle >& rStyleVector
-        , const ::std::map< css::uno::Reference< css::chart2::XDataSeries> , 
sal_Int32 >& rSeriesMap )
+        , ::std::map< css::uno::Reference< css::chart2::XDataSeries> , 
sal_Int32 >&& aSeriesMap )
 {
     //detect old series count
     //and add old series to aSeriesMap
-    ::std::map< css::uno::Reference<
-                css::chart2::XDataSeries >, sal_Int32 > aSeriesMap(rSeriesMap);
     sal_Int32 nOldSeriesCount = 0;
     {
         sal_Int32 nMaxOldSeriesIndex = 0;
diff --git a/xmloff/source/chart/SchXMLExport.cxx 
b/xmloff/source/chart/SchXMLExport.cxx
index 68e23a5616a9..b230a924472c 100644
--- a/xmloff/source/chart/SchXMLExport.cxx
+++ b/xmloff/source/chart/SchXMLExport.cxx
@@ -204,7 +204,7 @@ public:
      */
     ::std::queue< OUString > maAutoStyleNameQueue;
     void CollectAutoStyle(
-        const std::vector< XMLPropertyState >& aStates );
+        std::vector< XMLPropertyState >&& aStates );
     void AddAutoStyleAttribute(
         const std::vector< XMLPropertyState >& aStates );
 
@@ -1296,7 +1296,7 @@ void SchXMLExportHelper_Impl::parseDocument( Reference< 
chart::XChartDocument >
     }
     else    // autostyles
     {
-        CollectAutoStyle( aPropertyStates );
+        CollectAutoStyle( std::move(aPropertyStates) );
     }
     // remove property states for autostyles
     aPropertyStates.clear();
@@ -1335,7 +1335,7 @@ void SchXMLExportHelper_Impl::parseDocument( Reference< 
chart::XChartDocument >
         }
         else    // autostyles
         {
-            CollectAutoStyle( aPropertyStates );
+            CollectAutoStyle( std::move(aPropertyStates) );
         }
         // remove property states for autostyles
         aPropertyStates.clear();
@@ -1376,7 +1376,7 @@ void SchXMLExportHelper_Impl::parseDocument( Reference< 
chart::XChartDocument >
         }
         else    // autostyles
         {
-            CollectAutoStyle( aPropertyStates );
+            CollectAutoStyle( std::move(aPropertyStates) );
         }
         // remove property states for autostyles
         aPropertyStates.clear();
@@ -1481,7 +1481,7 @@ void SchXMLExportHelper_Impl::parseDocument( Reference< 
chart::XChartDocument >
         }
         else    // autostyles
         {
-            CollectAutoStyle( aPropertyStates );
+            CollectAutoStyle( std::move(aPropertyStates) );
         }
         // remove property states for autostyles
         aPropertyStates.clear();
@@ -1997,7 +1997,7 @@ void SchXMLExportHelper_Impl::exportPlotArea(
     }
     else    // autostyles
     {
-        CollectAutoStyle( aPropertyStates );
+        CollectAutoStyle( std::move(aPropertyStates) );
     }
     // remove property states for autostyles
     aPropertyStates.clear();
@@ -2033,7 +2033,7 @@ void SchXMLExportHelper_Impl::exportPlotArea(
                     }
                     else
                     {
-                        CollectAutoStyle( aPropertyStates );
+                        CollectAutoStyle( std::move(aPropertyStates) );
                     }
                 }
             }
@@ -2055,7 +2055,7 @@ void SchXMLExportHelper_Impl::exportPlotArea(
                     }
                     else
                     {
-                        CollectAutoStyle( aPropertyStates );
+                        CollectAutoStyle( std::move(aPropertyStates) );
                     }
                 }
             }
@@ -2077,7 +2077,7 @@ void SchXMLExportHelper_Impl::exportPlotArea(
                     }
                     else
                     {
-                        CollectAutoStyle( aPropertyStates );
+                        CollectAutoStyle( std::move(aPropertyStates) );
                     }
                 }
             }
@@ -2110,7 +2110,7 @@ void SchXMLExportHelper_Impl::exportPlotArea(
             }
             else    // autostyles
             {
-                CollectAutoStyle( aPropertyStates );
+                CollectAutoStyle( std::move(aPropertyStates) );
             }
         }
     }
@@ -2138,7 +2138,7 @@ void SchXMLExportHelper_Impl::exportPlotArea(
     }
     else    // autostyles
     {
-        CollectAutoStyle( aPropertyStates );
+        CollectAutoStyle( std::move(aPropertyStates) );
     }
 }
 
@@ -2235,7 +2235,7 @@ void SchXMLExportHelper_Impl::exportAxisTitle( const 
Reference< beans::XProperty
     }
     else
     {
-        CollectAutoStyle( aPropertyStates );
+        CollectAutoStyle( std::move(aPropertyStates) );
     }
     aPropertyStates.clear();
 }
@@ -2253,7 +2253,7 @@ void SchXMLExportHelper_Impl::exportGrid( const 
Reference< beans::XPropertySet >
     }
     else
     {
-        CollectAutoStyle( aPropertyStates );
+        CollectAutoStyle( std::move(aPropertyStates) );
     }
     aPropertyStates.clear();
 }
@@ -2384,7 +2384,7 @@ void SchXMLExportHelper_Impl::exportAxis(
     }
     else
     {
-        CollectAutoStyle( aPropertyStates );
+        CollectAutoStyle( std::move(aPropertyStates) );
     }
     aPropertyStates.clear();
 
@@ -2862,7 +2862,7 @@ void SchXMLExportHelper_Impl::exportSeries(
                             }
                             else    // autostyles
                             {
-                                CollectAutoStyle( aPropertyStates );
+                                CollectAutoStyle( std::move(aPropertyStates) );
                             }
                             // remove property states for autostyles
                             aPropertyStates.clear();
@@ -2955,7 +2955,7 @@ void SchXMLExportHelper_Impl::exportSeries(
                                 }
                                 else    // autostyles
                                 {
-                                    CollectAutoStyle( aPropertyStates );
+                                    CollectAutoStyle( 
std::move(aPropertyStates) );
                                 }
                             }
                         }
@@ -3003,7 +3003,7 @@ void SchXMLExportHelper_Impl::exportSeries(
                     {
                         // add the style for the to be <chart:data-label> too
                         if (!aDataLabelPropertyStates.empty())
-                            CollectAutoStyle(aDataLabelPropertyStates);
+                            
CollectAutoStyle(std::move(aDataLabelPropertyStates));
                     }
                     aDataLabelPropertyStates.clear();
 
@@ -3161,11 +3161,11 @@ void SchXMLExportHelper_Impl::exportRegressionCurve(
             {
                 if( !aPropertyStates.empty())
                 {
-                    CollectAutoStyle( aPropertyStates );
+                    CollectAutoStyle( std::move(aPropertyStates) );
                 }
                 if( bExportEquation && !aEquationPropertyStates.empty())
                 {
-                    CollectAutoStyle( aEquationPropertyStates );
+                    CollectAutoStyle( std::move(aEquationPropertyStates) );
                 }
             }
         }
@@ -3245,7 +3245,7 @@ void SchXMLExportHelper_Impl::exportErrorBar( const 
Reference<beans::XPropertySe
     }
     else    // autostyles
     {
-        CollectAutoStyle( aPropertyStates );
+        CollectAutoStyle( std::move(aPropertyStates) );
     }
 }
 
@@ -3504,9 +3504,9 @@ void SchXMLExportHelper_Impl::exportDataPoints(
                     else
                     {
                         if (!aPropertyStates.empty())
-                            CollectAutoStyle(aPropertyStates);
+                            CollectAutoStyle(std::move(aPropertyStates));
                         if (!aDataLabelPropertyStates.empty())
-                            CollectAutoStyle(aDataLabelPropertyStates);
+                            
CollectAutoStyle(std::move(aDataLabelPropertyStates));
                     }
                 }
             }
@@ -3591,9 +3591,9 @@ void SchXMLExportHelper_Impl::exportDataPoints(
                     else
                     {
                         if (!aPropertyStates.empty())
-                            CollectAutoStyle(aPropertyStates);
+                            CollectAutoStyle(std::move(aPropertyStates));
                         if (!aDataLabelPropertyStates.empty())
-                            CollectAutoStyle(aDataLabelPropertyStates);
+                            
CollectAutoStyle(std::move(aDataLabelPropertyStates));
                     }
                     continue;
                 }
@@ -3773,10 +3773,10 @@ awt::Size SchXMLExportHelper_Impl::getPageSize( const 
Reference< chart2::XChartD
     return aSize;
 }
 
-void SchXMLExportHelper_Impl::CollectAutoStyle( const std::vector< 
XMLPropertyState >& aStates )
+void SchXMLExportHelper_Impl::CollectAutoStyle( std::vector< XMLPropertyState 
>&& aStates )
 {
     if( !aStates.empty() )
-        maAutoStyleNameQueue.push( mrAutoStylePool.Add( 
XmlStyleFamily::SCH_CHART_ID, aStates ));
+        maAutoStyleNameQueue.push( mrAutoStylePool.Add( 
XmlStyleFamily::SCH_CHART_ID, std::move(aStates) ));
 }
 
 void SchXMLExportHelper_Impl::AddAutoStyleAttribute( const std::vector< 
XMLPropertyState >& aStates )
diff --git a/xmloff/source/core/RDFaImportHelper.cxx 
b/xmloff/source/core/RDFaImportHelper.cxx
index 42b8c2e412d7..0dddb882207a 100644
--- a/xmloff/source/core/RDFaImportHelper.cxx
+++ b/xmloff/source/core/RDFaImportHelper.cxx
@@ -116,11 +116,11 @@ struct ParsedRDFaAttributes
 
     ParsedRDFaAttributes(
             OUString const & i_rAbout,
-            ::std::vector< OUString > const & i_rProperties,
+            ::std::vector< OUString >&& i_rProperties,
             OUString const & i_rContent,
             OUString const & i_rDatatype)
         : m_About(i_rAbout)
-        , m_Properties(i_rProperties)
+        , m_Properties(std::move(i_rProperties))
         , m_Content(i_rContent)
         , m_Datatype(i_rDatatype)
     { }
@@ -384,7 +384,7 @@ RDFaImportHelper::ParseRDFa(
     if (about.isEmpty()) {
         return std::shared_ptr<ParsedRDFaAttributes>();
     }
-    const ::std::vector< OUString > properties(
+    ::std::vector< OUString > properties(
         reader.ReadCURIEs(i_rProperty) );
     if (properties.empty()) {
         return std::shared_ptr<ParsedRDFaAttributes>();
@@ -393,7 +393,7 @@ RDFaImportHelper::ParseRDFa(
         ?   reader.ReadCURIE(i_rDatatype)
         :   OUString() );
     return std::make_shared<ParsedRDFaAttributes>(
-            about, properties, i_rContent, datatype);
+            about, std::move(properties), i_rContent, datatype);
 }
 
 void
diff --git a/xmloff/source/draw/sdxmlexp.cxx b/xmloff/source/draw/sdxmlexp.cxx
index 933a280739d5..a306236ac13e 100644
--- a/xmloff/source/draw/sdxmlexp.cxx
+++ b/xmloff/source/draw/sdxmlexp.cxx
@@ -1539,7 +1539,7 @@ OUString SdXMLExport::ImpCreatePresPageStyleName( const 
Reference<XDrawPage>& xD
             if(sStyleName.isEmpty())
             {
                 // Style did not exist, add it to AutoStalePool
-                sStyleName = 
GetAutoStylePool()->Add(XmlStyleFamily::SD_DRAWINGPAGE_ID, sStyleName, 
aPropStates);
+                sStyleName = 
GetAutoStylePool()->Add(XmlStyleFamily::SD_DRAWINGPAGE_ID, sStyleName, 
std::move(aPropStates));
             }
         }
     }
diff --git a/xmloff/source/draw/shapeexport.cxx 
b/xmloff/source/draw/shapeexport.cxx
index c00886f386e8..8cf4992340e1 100644
--- a/xmloff/source/draw/shapeexport.cxx
+++ b/xmloff/source/draw/shapeexport.cxx
@@ -436,7 +436,7 @@ void XMLShapeExport::collectShapeAutoStyles(const 
uno::Reference< drawing::XShap
             if(aShapeInfo.msStyleName.isEmpty())
             {
                 // Style did not exist, add it to AutoStalePool
-                aShapeInfo.msStyleName = 
mrExport.GetAutoStylePool()->Add(aShapeInfo.mnFamily, aParentName, aPropStates);
+                aShapeInfo.msStyleName = 
mrExport.GetAutoStylePool()->Add(aShapeInfo.mnFamily, aParentName, 
std::move(aPropStates));
             }
         }
 
@@ -485,7 +485,7 @@ void XMLShapeExport::collectShapeAutoStyles(const 
uno::Reference< drawing::XShap
                 if(aShapeInfo.msTextStyleName.isEmpty())
                 {
                     // Style did not exist, add it to AutoStalePool
-                    aShapeInfo.msTextStyleName = 
mrExport.GetAutoStylePool()->Add(XmlStyleFamily::TEXT_PARAGRAPH, "", 
aPropStates);
+                    aShapeInfo.msTextStyleName = 
mrExport.GetAutoStylePool()->Add(XmlStyleFamily::TEXT_PARAGRAPH, "", 
std::move(aPropStates));
                 }
             }
         }
diff --git a/xmloff/source/forms/layerexport.cxx 
b/xmloff/source/forms/layerexport.cxx
index c6d9edf17378..dc2d3221ad11 100644
--- a/xmloff/source/forms/layerexport.cxx
+++ b/xmloff/source/forms/layerexport.cxx
@@ -590,7 +590,7 @@ namespace xmloff
 
                 if ( !aPropertyStates.empty() )
                 {   // add to the style pool
-                    OUString sColumnStyleName = 
m_rContext.GetAutoStylePool()->Add( XmlStyleFamily::CONTROL_ID, aPropertyStates 
);
+                    OUString sColumnStyleName = 
m_rContext.GetAutoStylePool()->Add( XmlStyleFamily::CONTROL_ID, 
std::move(aPropertyStates) );
 
                     OSL_ENSURE( m_aGridColumnStyles.end() == 
m_aGridColumnStyles.find( xColumnProperties ),
                         
"OFormLayerXMLExport_Impl::collectGridColumnStylesAndIds: already have a style 
for this column!" );
diff --git a/xmloff/source/style/XMLPageExport.cxx 
b/xmloff/source/style/XMLPageExport.cxx
index b9f3c95a47d6..87de784951cb 100644
--- a/xmloff/source/style/XMLPageExport.cxx
+++ b/xmloff/source/style/XMLPageExport.cxx
@@ -78,12 +78,12 @@ void XMLPageExport::collectPageMasterAutoStyle(
             rEntry.sPageMasterName = rExport.GetAutoStylePool()->Find( 
XmlStyleFamily::PAGE_MASTER, sParent, aPropStates );
             if (rEntry.sPageMasterName.isEmpty())
             {
-                rEntry.sPageMasterName = 
rExport.GetAutoStylePool()->Add(XmlStyleFamily::PAGE_MASTER, sParent, 
aPropStates);
+                rEntry.sPageMasterName = 
rExport.GetAutoStylePool()->Add(XmlStyleFamily::PAGE_MASTER, sParent, 
std::move(aPropStates));
             }
         }
     }
     assert(m_xPageMasterDrawingPageExportPropMapper.is());
-    ::std::vector<XMLPropertyState> const aPropStates(
+    ::std::vector<XMLPropertyState> aPropStates(
         m_xPageMasterDrawingPageExportPropMapper->Filter(rExport, rPropSet));
     if (!aPropStates.empty())
     {
@@ -91,7 +91,7 @@ void XMLPageExport::collectPageMasterAutoStyle(
         rEntry.sDrawingPageStyleName = 
rExport.GetAutoStylePool()->Find(XmlStyleFamily::SD_DRAWINGPAGE_ID, sParent, 
aPropStates);
         if (rEntry.sDrawingPageStyleName.isEmpty())
         {
-            rEntry.sDrawingPageStyleName = 
rExport.GetAutoStylePool()->Add(XmlStyleFamily::SD_DRAWINGPAGE_ID, sParent, 
aPropStates);
+            rEntry.sDrawingPageStyleName = 
rExport.GetAutoStylePool()->Add(XmlStyleFamily::SD_DRAWINGPAGE_ID, sParent, 
std::move(aPropStates));
         }
     }
 }
diff --git a/xmloff/source/style/impastpl.cxx b/xmloff/source/style/impastpl.cxx
index c61f9351ffc3..fd7c84dc1642 100644
--- a/xmloff/source/style/impastpl.cxx
+++ b/xmloff/source/style/impastpl.cxx
@@ -148,8 +148,8 @@ static OUString any2string(const uno::Any& any)
 // Class SvXMLAutoStylePoolProperties_Impl
 // ctor class SvXMLAutoStylePoolProperties_Impl
 
-XMLAutoStylePoolProperties::XMLAutoStylePoolProperties( XMLAutoStyleFamily& 
rFamilyData, const vector< XMLPropertyState >& rProperties, OUString const & 
rParentName )
-: maProperties( rProperties ),
+XMLAutoStylePoolProperties::XMLAutoStylePoolProperties( XMLAutoStyleFamily& 
rFamilyData, vector< XMLPropertyState >&& rProperties, OUString const & 
rParentName )
+: maProperties( std::move(rProperties) ),
   mnPos       ( rFamilyData.mnCount )
 {
     static bool bHack = (getenv("LIBO_ONEWAY_STABLE_ODF_EXPORT") != nullptr);
@@ -272,7 +272,7 @@ struct ComparePartial
 // Adds an array of XMLPropertyState ( vector< XMLPropertyState > ) to list
 // if not added, yet.
 
-bool XMLAutoStylePoolParent::Add( XMLAutoStyleFamily& rFamilyData, const 
vector< XMLPropertyState >& rProperties, OUString& rName, bool bDontSeek )
+bool XMLAutoStylePoolParent::Add( XMLAutoStyleFamily& rFamilyData, vector< 
XMLPropertyState >&& rProperties, OUString& rName, bool bDontSeek )
 {
     XMLAutoStylePoolProperties *pProperties = nullptr;
     auto [itBegin, itEnd] = std::equal_range(m_PropertiesList.begin(), 
m_PropertiesList.end(), rProperties, ComparePartial{rFamilyData});
@@ -284,7 +284,7 @@ bool XMLAutoStylePoolParent::Add( XMLAutoStyleFamily& 
rFamilyData, const vector<
     bool bAdded = false;
     if( bDontSeek || !pProperties )
     {
-        pProperties = new XMLAutoStylePoolProperties( rFamilyData, 
rProperties, msParent );
+        pProperties = new XMLAutoStylePoolProperties( rFamilyData, 
std::move(rProperties), msParent );
         m_PropertiesList.insert(itBegin, 
std::unique_ptr<XMLAutoStylePoolProperties>(pProperties));
         bAdded = true;
     }
@@ -300,7 +300,7 @@ bool XMLAutoStylePoolParent::Add( XMLAutoStyleFamily& 
rFamilyData, const vector<
 // the same properties exists, a new one is added (like with bDontSeek).
 
 
-bool XMLAutoStylePoolParent::AddNamed( XMLAutoStyleFamily& rFamilyData, const 
vector< XMLPropertyState >& rProperties, const OUString& rName )
+bool XMLAutoStylePoolParent::AddNamed( XMLAutoStyleFamily& rFamilyData, 
vector< XMLPropertyState >&& rProperties, const OUString& rName )
 {
     if (rFamilyData.maNameSet.find(rName) != rFamilyData.maNameSet.end())
         return false;
@@ -308,7 +308,7 @@ bool XMLAutoStylePoolParent::AddNamed( XMLAutoStyleFamily& 
rFamilyData, const ve
     auto it = std::lower_bound(m_PropertiesList.begin(), 
m_PropertiesList.end(), rProperties, ComparePartial{rFamilyData});
 
     std::unique_ptr<XMLAutoStylePoolProperties> pProperties(
-        new XMLAutoStylePoolProperties(rFamilyData, rProperties, msParent));
+        new XMLAutoStylePoolProperties(rFamilyData, std::move(rProperties), 
msParent));
     // ignore the generated name
     pProperties->SetName( rName );
     m_PropertiesList.insert(it, std::move(pProperties));
@@ -453,7 +453,7 @@ void SvXMLAutoStylePoolP_Impl::GetRegisteredNames(
 
 bool SvXMLAutoStylePoolP_Impl::Add(
     OUString& rName, XmlStyleFamily nFamily, const OUString& rParentName,
-    const ::std::vector< XMLPropertyState >& rProperties, bool bDontSeek )
+    ::std::vector< XMLPropertyState >&& rProperties, bool bDontSeek )
 {
     XMLAutoStyleFamily aTemp(nFamily);
     auto const iter = m_FamilySet.find(aTemp);
@@ -466,7 +466,7 @@ bool SvXMLAutoStylePoolP_Impl::Add(
     XMLAutoStylePoolParent& rParent = **itPair.first;
 
     bool bRet = false;
-    if (rParent.Add(rFamily, rProperties, rName, bDontSeek))
+    if (rParent.Add(rFamily, std::move(rProperties), rName, bDontSeek))
     {
         rFamily.mnCount++;
         bRet = true;
@@ -477,7 +477,7 @@ bool SvXMLAutoStylePoolP_Impl::Add(
 
 bool SvXMLAutoStylePoolP_Impl::AddNamed(
     const OUString& rName, XmlStyleFamily nFamily, const OUString& rParentName,
-    const ::std::vector< XMLPropertyState >& rProperties )
+    std::vector< XMLPropertyState >&& rProperties )
 {
     // get family and parent the same way as in Add()
 
@@ -492,7 +492,7 @@ bool SvXMLAutoStylePoolP_Impl::AddNamed(
     XMLAutoStylePoolParent& rParent = **itPair.first;
 
     bool bRet = false;
-    if (rParent.AddNamed(rFamily, rProperties, rName))
+    if (rParent.AddNamed(rFamily, std::move(rProperties), rName))
     {
         rFamily.mnCount++;
         bRet = true;
diff --git a/xmloff/source/style/impastpl.hxx b/xmloff/source/style/impastpl.hxx
index 23ffed85728d..4645305e1dcb 100644
--- a/xmloff/source/style/impastpl.hxx
+++ b/xmloff/source/style/impastpl.hxx
@@ -49,7 +49,7 @@ class XMLAutoStylePoolProperties
 
 public:
 
-    XMLAutoStylePoolProperties( XMLAutoStyleFamily& rFamilyData, const 
::std::vector< XMLPropertyState >& rProperties, OUString const & rParentname );
+    XMLAutoStylePoolProperties( XMLAutoStyleFamily& rFamilyData, std::vector< 
XMLPropertyState >&& rProperties, OUString const & rParentname );
 
     const OUString& GetName() const { return msName; }
     const ::std::vector< XMLPropertyState >& GetProperties() const { return 
maProperties; }
@@ -77,9 +77,9 @@ public:
 
     ~XMLAutoStylePoolParent();
 
-    bool Add( XMLAutoStyleFamily& rFamilyData, const ::std::vector< 
XMLPropertyState >& rProperties, OUString& rName, bool bDontSeek );
+    bool Add( XMLAutoStyleFamily& rFamilyData, std::vector< XMLPropertyState 
>&& rProperties, OUString& rName, bool bDontSeek );
 
-    bool AddNamed( XMLAutoStyleFamily& rFamilyData, const ::std::vector< 
XMLPropertyState >& rProperties, const OUString& rName );
+    bool AddNamed( XMLAutoStyleFamily& rFamilyData, std::vector< 
XMLPropertyState >&& rProperties, const OUString& rName );
 
     OUString Find( const XMLAutoStyleFamily& rFamilyData, const ::std::vector< 
XMLPropertyState >& rProperties ) const;
 
@@ -158,13 +158,13 @@ public:
     bool Add(
         OUString& rName, XmlStyleFamily nFamily,
         const OUString& rParentName,
-        const ::std::vector< XMLPropertyState >& rProperties,
+        std::vector< XMLPropertyState >&& rProperties,
         bool bDontSeek = false );
 
     bool AddNamed(
         const OUString& rName, XmlStyleFamily nFamily,
         const OUString& rParentName,
-        const ::std::vector< XMLPropertyState >& rProperties );
+        std::vector< XMLPropertyState >&& rProperties );
 
     OUString Find( XmlStyleFamily nFamily, const OUString& rParent,
                           const ::std::vector< XMLPropertyState >& rProperties 
) const;
diff --git a/xmloff/source/style/xmlaustp.cxx b/xmloff/source/style/xmlaustp.cxx
index d274884a7848..859477250ece 100644
--- a/xmloff/source/style/xmlaustp.cxx
+++ b/xmloff/source/style/xmlaustp.cxx
@@ -331,32 +331,32 @@ void SvXMLAutoStylePoolP::RegisterNames(
 }
 
 OUString SvXMLAutoStylePoolP::Add( XmlStyleFamily nFamily,
-                                  const vector< XMLPropertyState >& 
rProperties )
+                                   vector< XMLPropertyState >&& rProperties )
 {
     OUString sName;
-    pImpl->Add(sName, nFamily, "", rProperties );
+    pImpl->Add(sName, nFamily, "", std::move(rProperties) );
     return sName;
 }
 
 OUString SvXMLAutoStylePoolP::Add( XmlStyleFamily nFamily,
                                   const OUString& rParent,
-                                  const vector< XMLPropertyState >& 
rProperties, bool bDontSeek )
+                                  vector< XMLPropertyState >&& rProperties, 
bool bDontSeek )
 {
     OUString sName;
-    pImpl->Add(sName, nFamily, rParent, rProperties, bDontSeek);
+    pImpl->Add(sName, nFamily, rParent, std::move(rProperties), bDontSeek);
     return sName;
 }
 
-bool SvXMLAutoStylePoolP::Add(OUString& rName, XmlStyleFamily nFamily, const 
OUString& rParent, const ::std::vector< XMLPropertyState >& rProperties )
+bool SvXMLAutoStylePoolP::Add(OUString& rName, XmlStyleFamily nFamily, const 
OUString& rParent, ::std::vector< XMLPropertyState >&& rProperties )
 {
-    return pImpl->Add(rName, nFamily, rParent, rProperties);
+    return pImpl->Add(rName, nFamily, rParent, std::move(rProperties));
 }
 
 bool SvXMLAutoStylePoolP::AddNamed( const OUString& rName, XmlStyleFamily 
nFamily, const OUString& rParent,
-                                        const ::std::vector< XMLPropertyState 
>& rProperties )
+                                    std::vector< XMLPropertyState >&& 
rProperties )
 
 {
-    return pImpl->AddNamed(rName, nFamily, rParent, rProperties);
+    return pImpl->AddNamed(rName, nFamily, rParent, std::move(rProperties));
 }
 
 OUString SvXMLAutoStylePoolP::Find( XmlStyleFamily nFamily,
diff --git a/xmloff/source/table/XMLTableExport.cxx 
b/xmloff/source/table/XMLTableExport.cxx
index c4baf426bf95..81488ec62543 100644
--- a/xmloff/source/table/XMLTableExport.cxx
+++ b/xmloff/source/table/XMLTableExport.cxx
@@ -239,7 +239,7 @@ static bool has_states( const std::vector< XMLPropertyState 
>& xPropStates )
 
             if( has_states( aPropStates ) )
             {
-                const OUString sStyleName( 
mrExport.GetAutoStylePool()->Add(XmlStyleFamily::TABLE_COLUMN, aPropStates) );
+                const OUString sStyleName( 
mrExport.GetAutoStylePool()->Add(XmlStyleFamily::TABLE_COLUMN, 
std::move(aPropStates)) );
                 Reference< XInterface > xKey( xPropSet, UNO_QUERY );
                 xTableInfo->maColumnStyleMap[xKey] = sStyleName;
             }
@@ -263,7 +263,7 @@ static bool has_states( const std::vector< XMLPropertyState 
>& xPropStates )
 
             if( has_states( aRowPropStates ) )
             {
-                const OUString sStyleName( 
mrExport.GetAutoStylePool()->Add(XmlStyleFamily::TABLE_ROW, aRowPropStates) );
+                const OUString sStyleName( 
mrExport.GetAutoStylePool()->Add(XmlStyleFamily::TABLE_ROW, 
std::move(aRowPropStates)) );
                 Reference< XInterface > xKey( xPropSet, UNO_QUERY );
                 xTableInfo->maRowStyleMap[xKey] = sStyleName;
             }
@@ -289,7 +289,7 @@ static bool has_states( const std::vector< XMLPropertyState 
>& xPropStates )
                 OUString sStyleName;
                 std::vector<XMLPropertyState> 
aCellPropStates(mxCellExportPropertySetMapper->Filter(mrExport, xCellSet));
                 if( has_states( aCellPropStates ) )
-                    sStyleName = 
mrExport.GetAutoStylePool()->Add(XmlStyleFamily::TABLE_CELL, aCellPropStates);
+                    sStyleName = 
mrExport.GetAutoStylePool()->Add(XmlStyleFamily::TABLE_CELL, 
std::move(aCellPropStates));
                 else
                     sStyleName = sParentStyleName;
 
diff --git a/xmloff/source/text/txtparae.cxx b/xmloff/source/text/txtparae.cxx
index 16822a03f09f..7257ac0061af 100644
--- a/xmloff/source/text/txtparae.cxx
+++ b/xmloff/source/text/txtparae.cxx
@@ -636,9 +636,9 @@ void XMLTextParagraphExport::Add( XmlStyleFamily nFamily,
     }
     if (aPropStates.size() - nIgnoreProps)
     {
-        GetAutoStylePool().Add( nFamily, sParent, aPropStates, bDontSeek );
+        GetAutoStylePool().Add( nFamily, sParent, std::vector(aPropStates), 
bDontSeek );
         if( !sCondParent.isEmpty() && sParent != sCondParent )
-            GetAutoStylePool().Add( nFamily, sCondParent, aPropStates );
+            GetAutoStylePool().Add( nFamily, sCondParent, 
std::move(aPropStates) );
     }
 }
 
@@ -725,9 +725,9 @@ void XMLTextParagraphExport::Add( XmlStyleFamily nFamily,
 
     if( std::any_of( aPropStates.begin(), aPropStates.end(), 
lcl_validPropState ) )
     {
-        GetAutoStylePool().Add( nFamily, sParent, aPropStates );
+        GetAutoStylePool().Add( nFamily, sParent, std::vector(aPropStates) );
         if( !sCondParent.isEmpty() && sParent != sCondParent )
-            GetAutoStylePool().Add( nFamily, sCondParent, aPropStates );
+            GetAutoStylePool().Add( nFamily, sCondParent, 
std::move(aPropStates) );
     }
 }
 

Reply via email to