[Marble-commits] KDE/kdeedu/marble/src/lib/geodata/scene

Jens-Michael Hoffmann jensmh at gmx.de
Fri Jul 10 16:58:57 CEST 2009


SVN commit 994399 by jmhoffmann:

Remove redundant assignments to iterator start position.


 M  +4 -4      GeoSceneMap.cpp  


--- trunk/KDE/kdeedu/marble/src/lib/geodata/scene/GeoSceneMap.cpp #994398:994399
@@ -92,7 +92,7 @@
     GeoSceneLayer* layer = 0;
 
     QVector<GeoSceneLayer*>::const_iterator it = d->m_layers.constBegin();
-    for (it = d->m_layers.constBegin(); it != d->m_layers.constEnd(); ++it) {
+    for (; it != d->m_layers.constEnd(); ++it) {
         if ( (*it)->name() == name )
             layer = *it;
     }
@@ -138,7 +138,7 @@
     GeoSceneFilter* filter = 0;
 
     QVector<GeoSceneFilter*>::const_iterator it = d->m_filters.constBegin();
-    for (it = d->m_filters.constBegin(); it != d->m_filters.constEnd(); ++it) {
+    for (; it != d->m_filters.constEnd(); ++it) {
         if ( (*it)->name() == name )
             filter = *it;
     }
@@ -162,7 +162,7 @@
 bool GeoSceneMap::hasTextureLayers() const
 {
     QVector<GeoSceneLayer*>::const_iterator it = d->m_layers.constBegin();
-    for (it = d->m_layers.constBegin(); it != d->m_layers.constEnd(); ++it) {
+    for (; it != d->m_layers.constEnd(); ++it) {
         if ( (*it)->backend() == dgml::dgmlValue_texture && (*it)->datasets().count() > 0 )
             return true;
     }
@@ -173,7 +173,7 @@
 bool GeoSceneMap::hasVectorLayers() const
 {
     QVector<GeoSceneLayer*>::const_iterator it = d->m_layers.constBegin();
-    for (it = d->m_layers.constBegin(); it != d->m_layers.constEnd(); ++it) {
+    for (; it != d->m_layers.constEnd(); ++it) {
         if ( (*it)->backend() == dgml::dgmlValue_vector && (*it)->datasets().count() > 0 )
             return true;
     }


More information about the Marble-commits mailing list