diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-09-13 16:43:57 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-09-14 08:29:11 +0200 |
commit | 2d2259c848b43f9f04d5bb6073c00b8ae124534a (patch) | |
tree | 28a3d6274bcb2ffa5b7c55c519fc07b4f2cfacc3 /toolkit/source | |
parent | b0b0aef18fff981fa1f4a1539c150260cc526595 (diff) |
clang-tidy modernize-use-emplace in test..vbahelper
Change-Id: Ifbe1dd7c9d5dde33f7419548670434591b1a1d82
Reviewed-on: https://gerrit.libreoffice.org/42258
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'toolkit/source')
-rw-r--r-- | toolkit/source/awt/animatedimagespeer.cxx | 2 | ||||
-rw-r--r-- | toolkit/source/controls/controlmodelcontainerbase.cxx | 4 | ||||
-rw-r--r-- | toolkit/source/controls/geometrycontrolmodel.cxx | 2 | ||||
-rw-r--r-- | toolkit/source/controls/unocontrol.cxx | 5 |
4 files changed, 6 insertions, 7 deletions
diff --git a/toolkit/source/awt/animatedimagespeer.cxx b/toolkit/source/awt/animatedimagespeer.cxx index e33b9ac1ada0..31661a7724e3 100644 --- a/toolkit/source/awt/animatedimagespeer.cxx +++ b/toolkit/source/awt/animatedimagespeer.cxx @@ -171,7 +171,7 @@ namespace toolkit o_images.reserve( count ); for ( size_t i = 0; i < count; ++i ) { - o_images.push_back( CachedImage( i_imageURLs[i] ) ); + o_images.emplace_back( i_imageURLs[i] ); } } diff --git a/toolkit/source/controls/controlmodelcontainerbase.cxx b/toolkit/source/controls/controlmodelcontainerbase.cxx index 223d888cae10..551dda47a63c 100644 --- a/toolkit/source/controls/controlmodelcontainerbase.cxx +++ b/toolkit/source/controls/controlmodelcontainerbase.cxx @@ -147,7 +147,7 @@ public: Reference< XCloneable > xCloneSource( _rSource.first, UNO_QUERY ); Reference< XControlModel > xClone( xCloneSource->createClone(), UNO_QUERY ); // add to target list - m_rTargetList.push_back( ControlModelContainerBase::UnoControlModelHolder( xClone, _rSource.second ) ); + m_rTargetList.emplace_back( xClone, _rSource.second ); } }; @@ -594,7 +594,7 @@ void ControlModelContainerBase::insertByName( const OUString& aName, const Any& if ( xAllChildren.is() ) updateUserFormChildren( xAllChildren, aName, Insert, xM ); - maModels.push_back( UnoControlModelHolder( xM, aName ) ); + maModels.emplace_back( xM, aName ); mbGroupsUpToDate = false; startControlListening( xM ); diff --git a/toolkit/source/controls/geometrycontrolmodel.cxx b/toolkit/source/controls/geometrycontrolmodel.cxx index 5e3f3767cc48..439da5a054c1 100644 --- a/toolkit/source/controls/geometrycontrolmodel.cxx +++ b/toolkit/source/controls/geometrycontrolmodel.cxx @@ -483,7 +483,7 @@ PropSeqArray &rAggProperties = AggregateProperties::get(); m_nPropertyMapId = rAggProperties.size(); rAggProperties.push_back( xPI->getProperties() ); - AmbiguousPropertyIds::get().push_back( IntArrayArray::value_type() ); + AmbiguousPropertyIds::get().emplace_back( ); rMap[ m_sServiceSpecifier ] = m_nPropertyMapId; } diff --git a/toolkit/source/controls/unocontrol.cxx b/toolkit/source/controls/unocontrol.cxx index 956628615cc5..02e393f39af9 100644 --- a/toolkit/source/controls/unocontrol.cxx +++ b/toolkit/source/controls/unocontrol.cxx @@ -530,7 +530,7 @@ void UnoControl::ImplModelPropertiesChanged( const Sequence< PropertyChangeEvent // Add properties with dependencies on other properties last // since they're dependent on properties added later (such as // VALUE dependency on VALUEMIN/MAX) - aPeerPropertiesToSet.push_back(PropertyValue(pEvents->PropertyName, 0, pEvents->NewValue, PropertyState_DIRECT_VALUE)); + aPeerPropertiesToSet.emplace_back(pEvents->PropertyName, 0, pEvents->NewValue, PropertyState_DIRECT_VALUE); } else { @@ -600,8 +600,7 @@ void UnoControl::ImplModelPropertiesChanged( const Sequence< PropertyChangeEvent OUString aPropName( OUString::createFromAscii( pLangDepProp->pPropName )); if ( xPSI.is() && xPSI->hasPropertyByName( aPropName ) ) { - aPeerPropertiesToSet.push_back( - PropertyValue( aPropName, 0, xPS->getPropertyValue( aPropName ), PropertyState_DIRECT_VALUE ) ); + aPeerPropertiesToSet.emplace_back( aPropName, 0, xPS->getPropertyValue( aPropName ), PropertyState_DIRECT_VALUE ); } } |