[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    [marble] src/plugins/runner/osm: establish invariant: set a popularity in any case also for OSM node
From:       Bernhard Beschow <bbeschow () cs ! tu-berlin ! de>
Date:       2016-11-06 21:17:07
Message-ID: E1c3UoN-0000aL-0s () code ! kde ! org
[Download RAW message or body]

Git commit 8483e5f322babb7f7f4a0eb723c3a5de76a02eb1 by Bernhard Beschow.
Committed on 06/11/2016 at 21:17.
Pushed by beschow into branch 'master'.

establish invariant: set a popularity in any case also for OSM nodes

M  +2    -1    src/plugins/runner/osm/OsmNode.cpp

http://commits.kde.org/marble/8483e5f322babb7f7f4a0eb723c3a5de76a02eb1

diff --git a/src/plugins/runner/osm/OsmNode.cpp b/src/plugins/runner/osm/OsmNode.cpp
index 68bbff3..3f839b5 100644
--- a/src/plugins/runner/osm/OsmNode.cpp
+++ b/src/plugins/runner/osm/OsmNode.cpp
@@ -69,9 +69,10 @@ void OsmNode::create(GeoDataDocument *document) const
         placemark->setZoomLevel(zoomLevel);
     } else {
         placemark->setZoomLevel(zoomLevelFor(category, 18));
-        placemark->setPopularity(popularityFor(category, 100));
     }
 
+    placemark->setPopularity(popularityFor(category, 100));
+
     if (category >= GeoDataPlacemark::PlaceCity && category <= GeoDataPlacemark::PlaceVillageCapital) {
         int const population = m_osmData.tagValue(QStringLiteral("population")).toInt();
         placemark->setPopulation(qMax(0, population));
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic