summaryrefslogtreecommitdiff
path: root/xmloff/source/style/impastpl.cxx
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2016-05-12 10:07:50 +0200
committerNoel Grandin <noelgrandin@gmail.com>2016-05-13 08:09:03 +0000
commit96fab0513215cc416e96e1b2089466afd0d2791c (patch)
tree7c03bd56b0c3744f0560c05ebb2f422155e64543 /xmloff/source/style/impastpl.cxx
parentb3d5da663ff09c72455a8d3bf9be7c00220271bb (diff)
clang-tidy modernize-loop-convert in writerfilter to xmlsecurity
Change-Id: I334411c6b57c028ffb41b5deb72002f9d54038c3 Reviewed-on: https://gerrit.libreoffice.org/24923 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'xmloff/source/style/impastpl.cxx')
-rw-r--r--xmloff/source/style/impastpl.cxx11
1 files changed, 5 insertions, 6 deletions
diff --git a/xmloff/source/style/impastpl.cxx b/xmloff/source/style/impastpl.cxx
index 2d4959ee1d9d..8d2305aeca4d 100644
--- a/xmloff/source/style/impastpl.cxx
+++ b/xmloff/source/style/impastpl.cxx
@@ -189,9 +189,8 @@ XMLAutoStylePoolProperties::XMLAutoStylePoolProperties( XMLAutoStyleFamily& rFam
}
// Create a name based on the properties used
- for( size_t i = 0, n = maProperties.size(); i < n; ++i )
+ for(XMLPropertyState & rState : maProperties)
{
- XMLPropertyState& rState = maProperties[i];
if (rState.mnIndex == -1)
continue;
OUString sXMLName(rFamilyData.mxMapper->getPropertySetMapper()->GetEntryXMLName(rState.mnIndex));
@@ -250,9 +249,9 @@ XMLAutoStylePoolProperties::XMLAutoStylePoolProperties( XMLAutoStyleFamily& rFam
#if OSL_DEBUG_LEVEL > 0
std::set<sal_Int32> DebugProperties;
- for (size_t i = 0; i < maProperties.size(); ++i)
+ for (XMLPropertyState & rPropState : maProperties)
{
- sal_Int32 const property(maProperties[i].mnIndex);
+ sal_Int32 const property(rPropState.mnIndex);
// serious bug: will cause duplicate attributes to be exported
assert(DebugProperties.find(property) == DebugProperties.end());
if (-1 != property)
@@ -361,9 +360,9 @@ OUString XMLAutoStylePoolParent::Find( const XMLAutoStyleFamily& rFamilyData, co
{
OUString sName;
vector< XMLPropertyState>::size_type nItems = rProperties.size();
- for (size_t i = 0, n = m_PropertiesList.size(); i < n; ++i)
+ for (const auto & i : m_PropertiesList)
{
- const XMLAutoStylePoolProperties *const pIS = m_PropertiesList[i].get();
+ const XMLAutoStylePoolProperties *const pIS = i.get();
if( nItems > pIS->GetProperties().size() )
{
continue;