summaryrefslogtreecommitdiff
path: root/svl/source/items/macitem.cxx
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-08-10 16:43:55 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-08-11 12:38:32 +0200
commitd347c2403605c5aa3ddd98fb605366914acab79f (patch)
treee39624030741234c514bccd858e69d6318dfba68 /svl/source/items/macitem.cxx
parentf0e68d4feaaa43f7450432ad1ebd92c2b572400f (diff)
convert std::map::insert to std::map::emplace
which is considerably less verbose Change-Id: Ifa373e8eb09e39bd6c8d3578641610a6055a187b Reviewed-on: https://gerrit.libreoffice.org/40978 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'svl/source/items/macitem.cxx')
-rw-r--r--svl/source/items/macitem.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/svl/source/items/macitem.cxx b/svl/source/items/macitem.cxx
index 505039c86d71..01a4ebd82993 100644
--- a/svl/source/items/macitem.cxx
+++ b/svl/source/items/macitem.cxx
@@ -131,7 +131,7 @@ void SvxMacroTableDtor::Read( SvStream& rStrm, sal_uInt16 nVersion )
if( SVX_MACROTBL_VERSION40 <= nVersion )
rStrm.ReadUInt16( eType );
- aSvxMacroTable.insert( SvxMacroTable::value_type(SvMacroItemId(nCurKey), SvxMacro( aMacName, aLibName, (ScriptType)eType ) ));
+ aSvxMacroTable.emplace( SvMacroItemId(nCurKey), SvxMacro( aMacName, aLibName, (ScriptType)eType ) );
}
}
@@ -186,7 +186,7 @@ bool SvxMacroTableDtor::IsKeyValid(SvMacroItemId nEvent) const
// This stores a copy of the rMacro parameter
SvxMacro& SvxMacroTableDtor::Insert(SvMacroItemId nEvent, const SvxMacro& rMacro)
{
- return aSvxMacroTable.insert( SvxMacroTable::value_type( nEvent, rMacro ) ).first->second;
+ return aSvxMacroTable.emplace( nEvent, rMacro ).first->second;
}
// If the entry exists, remove it from the map and release it's storage