summaryrefslogtreecommitdiff
path: root/chart2
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2019-05-08 08:29:46 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2019-05-09 08:47:50 +0200
commite0382c3ad7786910bc9aa81cf581798df0f2508c (patch)
tree6acb0196add99896ced2aa1a76ff5b432bc45401 /chart2
parent38a684f72988f29e1c07bf9fa5a83e275e80e24c (diff)
avoid copying when placing items into SfxItemSet
Change-Id: I05c627f590e7794c1ba11b66021dc30aa3285eb0 Reviewed-on: https://gerrit.libreoffice.org/71941 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'chart2')
-rw-r--r--chart2/source/controller/itemsetwrapper/GraphicPropertyItemConverter.cxx8
-rw-r--r--chart2/source/controller/itemsetwrapper/ItemConverter.cxx2
2 files changed, 5 insertions, 5 deletions
diff --git a/chart2/source/controller/itemsetwrapper/GraphicPropertyItemConverter.cxx b/chart2/source/controller/itemsetwrapper/GraphicPropertyItemConverter.cxx
index e709a0f397af..fa253a6830e3 100644
--- a/chart2/source/controller/itemsetwrapper/GraphicPropertyItemConverter.cxx
+++ b/chart2/source/controller/itemsetwrapper/GraphicPropertyItemConverter.cxx
@@ -295,7 +295,7 @@ void GraphicPropertyItemConverter::FillSpecialItem(
std::unique_ptr<XLineDashItem> pItemToPut = aItem.checkForUniqueItem( & m_rDrawModel );
if(pItemToPut)
- rOutItemSet.Put( *pItemToPut );
+ rOutItemSet.Put( std::move(pItemToPut) );
else
rOutItemSet.Put(aItem);
}
@@ -321,7 +321,7 @@ void GraphicPropertyItemConverter::FillSpecialItem(
std::unique_ptr<XFillGradientItem> pItemToPut = aItem.checkForUniqueItem( & m_rDrawModel );
if(pItemToPut)
- rOutItemSet.Put( *pItemToPut );
+ rOutItemSet.Put(std::move(pItemToPut) );
else
rOutItemSet.Put(aItem);
}
@@ -347,7 +347,7 @@ void GraphicPropertyItemConverter::FillSpecialItem(
std::unique_ptr<XFillHatchItem> pItemToPut = aItem.checkForUniqueItem( & m_rDrawModel );
if(pItemToPut)
- rOutItemSet.Put( *pItemToPut );
+ rOutItemSet.Put( std::move(pItemToPut) );
else
rOutItemSet.Put(aItem);
}
@@ -368,7 +368,7 @@ void GraphicPropertyItemConverter::FillSpecialItem(
std::unique_ptr<XFillBitmapItem> pItemToPut = aItem.checkForUniqueItem( & m_rDrawModel );
if(pItemToPut)
- rOutItemSet.Put( *pItemToPut );
+ rOutItemSet.Put( std::move(pItemToPut) );
else
rOutItemSet.Put(aItem);
}
diff --git a/chart2/source/controller/itemsetwrapper/ItemConverter.cxx b/chart2/source/controller/itemsetwrapper/ItemConverter.cxx
index 6fd5ac749a1f..c0f7f0da3276 100644
--- a/chart2/source/controller/itemsetwrapper/ItemConverter.cxx
+++ b/chart2/source/controller/itemsetwrapper/ItemConverter.cxx
@@ -107,7 +107,7 @@ void ItemConverter::FillItemSet( SfxItemSet & rOutItemSet ) const
))
{
pItem->SetWhich(nWhich);
- rOutItemSet.Put( *pItem );
+ rOutItemSet.Put( std::move(pItem) );
}
}
catch( const beans::UnknownPropertyException &ex )