summaryrefslogtreecommitdiff
path: root/xmloff/source/chart/SchXMLAutoStylePoolP.cxx
diff options
context:
space:
mode:
authorArkadiy Illarionov <qarkai@gmail.com>2018-09-19 08:25:34 +0300
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-09-25 08:55:12 +0200
commitdaf44342ca82c5b0e79da88b7f9dbf28f6d43a8b (patch)
tree54517341b968d644de2e48028d1974f14c70e248 /xmloff/source/chart/SchXMLAutoStylePoolP.cxx
parent49614a9ea971ff7f370f863ce8a2735aab973cee (diff)
Simplify containers iterations in xmloff/source/[c-d]*
Use range-based loop or replace with STL functions. Change-Id: I2af2d739d55a0bf480bb6e9d57b49dd16806af30 Reviewed-on: https://gerrit.libreoffice.org/60734 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'xmloff/source/chart/SchXMLAutoStylePoolP.cxx')
-rw-r--r--xmloff/source/chart/SchXMLAutoStylePoolP.cxx13
1 files changed, 6 insertions, 7 deletions
diff --git a/xmloff/source/chart/SchXMLAutoStylePoolP.cxx b/xmloff/source/chart/SchXMLAutoStylePoolP.cxx
index 087e890b4826..ee5081c489ab 100644
--- a/xmloff/source/chart/SchXMLAutoStylePoolP.cxx
+++ b/xmloff/source/chart/SchXMLAutoStylePoolP.cxx
@@ -48,27 +48,26 @@ void SchXMLAutoStylePoolP::exportStyleAttributes(
if( nFamily == XML_STYLE_FAMILY_SCH_CHART_ID )
{
- for( ::std::vector< XMLPropertyState >::const_iterator iter = rProperties.begin();
- (iter != rProperties.end()); ++iter )
+ for( const auto& rProp : rProperties )
{
- if( iter->mnIndex == -1 )
+ if( rProp.mnIndex == -1 )
continue;
rtl::Reference< XMLPropertySetMapper > aPropMapper =
mrSchXMLExport.GetPropertySetMapper();
- sal_Int16 nContextID = aPropMapper->GetEntryContextId( iter->mnIndex );
+ sal_Int16 nContextID = aPropMapper->GetEntryContextId( rProp.mnIndex );
if( nContextID == XML_SCH_CONTEXT_SPECIAL_NUMBER_FORMAT )
{
sal_Int32 nNumberFormat = -1;
- if( ( iter->maValue >>= nNumberFormat ) &&
+ if( ( rProp.maValue >>= nNumberFormat ) &&
( nNumberFormat != -1 ))
{
OUString sAttrValue = mrSchXMLExport.getDataStyleName( nNumberFormat );
if( !sAttrValue.isEmpty() )
{
mrSchXMLExport.AddAttribute(
- aPropMapper->GetEntryNameSpace( iter->mnIndex ),
- aPropMapper->GetEntryXMLName( iter->mnIndex ),
+ aPropMapper->GetEntryNameSpace( rProp.mnIndex ),
+ aPropMapper->GetEntryXMLName( rProp.mnIndex ),
sAttrValue );
}
}