summaryrefslogtreecommitdiff
path: root/src/plugins/geoservices/mapbox/qgeotiledmappingmanagerenginemapbox.cpp
diff options
context:
space:
mode:
authorPaolo Angelelli <paolo.angelelli@qt.io>2018-02-14 18:20:15 +0100
committerPaolo Angelelli <paolo.angelelli@qt.io>2018-04-17 13:02:53 +0000
commit2782765e20ba3bc6af92375574456fd54d4243f7 (patch)
tree9a70096fdddcc7d28224d6749dd0c7b0da5bcdbb /src/plugins/geoservices/mapbox/qgeotiledmappingmanagerenginemapbox.cpp
parent05edc644337a33e3e72d993b8114efc755a4320a (diff)
downloadqtlocation-2782765e20ba3bc6af92375574456fd54d4243f7.tar.gz
Introduce map objects reference implementation
This patch introduces a reference implementation for the QGeoMapObject subclasses in the locationlabs module. If this module is built, all current plugins, with the exception of mapboxgl, will also be able to render map objects. The current reference implementation of map objects is not optimized, but it can be useful for both testing and feature parity (so that switching between plugins will give the same result). Change-Id: I830ebb3813f219e42c085f450952a2b4327361cd Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
Diffstat (limited to 'src/plugins/geoservices/mapbox/qgeotiledmappingmanagerenginemapbox.cpp')
-rw-r--r--src/plugins/geoservices/mapbox/qgeotiledmappingmanagerenginemapbox.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/plugins/geoservices/mapbox/qgeotiledmappingmanagerenginemapbox.cpp b/src/plugins/geoservices/mapbox/qgeotiledmappingmanagerenginemapbox.cpp
index 632b2286..f2595d03 100644
--- a/src/plugins/geoservices/mapbox/qgeotiledmappingmanagerenginemapbox.cpp
+++ b/src/plugins/geoservices/mapbox/qgeotiledmappingmanagerenginemapbox.cpp
@@ -41,6 +41,12 @@
#include <QtLocation/private/qgeomaptype_p.h>
#include <QtLocation/private/qgeotiledmap_p.h>
#include "qgeofiletilecachemapbox.h"
+#ifdef LOCATIONLABS
+#include <QtLocation/private/qgeotiledmaplabs_p.h>
+typedef QGeoTiledMapLabs Map;
+#else
+typedef QGeoTiledMap Map;
+#endif
QT_BEGIN_NAMESPACE
@@ -246,7 +252,7 @@ QGeoTiledMappingManagerEngineMapbox::~QGeoTiledMappingManagerEngineMapbox()
QGeoMap *QGeoTiledMappingManagerEngineMapbox::createMap()
{
- QGeoTiledMap *map = new QGeoTiledMap(this, 0);
+ QGeoTiledMap *map = new Map(this, 0);
map->setPrefetchStyle(m_prefetchStyle);
return map;
}