summaryrefslogtreecommitdiff
path: root/chart2/source/model
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-11-09 12:59:44 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-11-09 13:57:45 +0100
commita93b691b78c95676d0dcf2724563aa1a8a5a2e8e (patch)
tree96aeaa5837666e9d7a000990ea3453a66f3435cc /chart2/source/model
parent4887f9fe2d5bdbf8d760d88a984439efbdf37d5a (diff)
loplugin:unusedvariable add some more std:: types
Change-Id: Ib15931e415990b56367fe3e1c7cf3f22cc4826d5 Reviewed-on: https://gerrit.libreoffice.org/44529 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'chart2/source/model')
-rw-r--r--chart2/source/model/main/Diagram.cxx20
1 files changed, 6 insertions, 14 deletions
diff --git a/chart2/source/model/main/Diagram.cxx b/chart2/source/model/main/Diagram.cxx
index 9895a7f470b4..136db02b14e2 100644
--- a/chart2/source/model/main/Diagram.cxx
+++ b/chart2/source/model/main/Diagram.cxx
@@ -254,33 +254,26 @@ struct StaticDiagramInfo : public rtl::StaticAggregate< uno::Reference< beans::X
/// clones a UNO-sequence of UNO-References
typedef Reference< chart2::XCoordinateSystem > lcl_tCooSysRef;
-typedef std::map< lcl_tCooSysRef, lcl_tCooSysRef > lcl_tCooSysMapping;
-typedef std::vector< lcl_tCooSysRef > lcl_tCooSysVector;
+typedef std::vector< lcl_tCooSysRef > lcl_tCooSysVector;
-lcl_tCooSysMapping lcl_CloneCoordinateSystems(
+void lcl_CloneCoordinateSystems(
const lcl_tCooSysVector & rSource,
lcl_tCooSysVector & rDestination )
{
- lcl_tCooSysMapping aResult;
-
- for( lcl_tCooSysVector::const_iterator aIt( rSource.begin());
- aIt != rSource.end(); ++aIt )
+ for( auto const & i : rSource )
{
lcl_tCooSysRef xClone;
- css::uno::Reference< css::util::XCloneable > xCloneable( *aIt, css::uno::UNO_QUERY );
+ css::uno::Reference< css::util::XCloneable > xCloneable( i, css::uno::UNO_QUERY );
if( xCloneable.is())
xClone.set( xCloneable->createClone(), css::uno::UNO_QUERY );
if( xClone.is())
{
rDestination.push_back( xClone );
- aResult.emplace( *aIt, xClone );
}
else
- rDestination.push_back( *aIt );
+ rDestination.push_back( i );
}
-
- return aResult;
}
} // anonymous namespace
@@ -309,8 +302,7 @@ Diagram::Diagram( const Diagram & rOther ) :
m_xContext( rOther.m_xContext ),
m_xModifyEventForwarder( ModifyListenerHelper::createModifyEventForwarder())
{
- lcl_tCooSysMapping aCooSysMapping =
- lcl_CloneCoordinateSystems( rOther.m_aCoordSystems, m_aCoordSystems );
+ lcl_CloneCoordinateSystems( rOther.m_aCoordSystems, m_aCoordSystems );
ModifyListenerHelper::addListenerToAllElements( m_aCoordSystems, m_xModifyEventForwarder );
m_xWall.set( CloneHelper::CreateRefClone< beans::XPropertySet >()( rOther.m_xWall ));