summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKatja Marttila <katja.marttila@qt.io>2016-11-14 14:22:30 +0200
committerPaolo Angelelli <paolo.angelelli@qt.io>2016-11-14 15:18:25 +0000
commit951737a4905c6bd8d7d8041ba179da51c49fd372 (patch)
tree7f12092c7ae780df6bcd6380b44053bf57b54632
parent4f192687cc07dbe5de1dbed3187d90045ed38703 (diff)
downloadqtlocation-951737a4905c6bd8d7d8041ba179da51c49fd372.tar.gz
Fix mapbox map loading in offline mode
When in offline, tiles are parsed from cache using filename. Parsing was done incorrectly for mapbox as it assumed that mapbox does not have full comma in filename which it does. Task-number: QTBUG-57011 Change-Id: I731950dc5ef8780ffe75e239462840068afa5f53 Reviewed-by: Paolo Angelelli <paolo.angelelli@qt.io>
-rw-r--r--src/plugins/geoservices/mapbox/qgeofiletilecachemapbox.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/plugins/geoservices/mapbox/qgeofiletilecachemapbox.cpp b/src/plugins/geoservices/mapbox/qgeofiletilecachemapbox.cpp
index 6ce41a2b..8cc3622b 100644
--- a/src/plugins/geoservices/mapbox/qgeofiletilecachemapbox.cpp
+++ b/src/plugins/geoservices/mapbox/qgeofiletilecachemapbox.cpp
@@ -87,10 +87,10 @@ QGeoTileSpec QGeoFileTileCacheMapbox::filenameToTileSpec(const QString &filename
{
QStringList parts = filename.split('.');
- if (parts.length() != 2)
+ if (parts.length() != 3)
return QGeoTileSpec();
- QString name = parts.at(0);
+ QString name = parts.at(0) + parts.at(1);
QStringList fields = name.split('-');
int length = fields.length();