diff options
author | Paolo Angelelli <paolo.angelelli@qt.io> | 2017-02-10 19:05:56 +0100 |
---|---|---|
committer | Paolo Angelelli <paolo.angelelli@qt.io> | 2017-02-28 11:09:56 +0000 |
commit | ba2a82b7db86d96fc1f110b4bbc88408f47a5774 (patch) | |
tree | 66bb4e03d6cff164cac4161b4363e3444a78ad23 /src/location/maps/qgeomap_p_p.h | |
parent | 11e6a62957433843816b41ad11fada7ca8eab85c (diff) | |
download | qtlocation-ba2a82b7db86d96fc1f110b4bbc88408f47a5774.tar.gz |
Make QGeoCameraCapabilities independent of the engine
This patch makes it possible to change QGeoCameraCapabilites
at runtime, when the map type changes, to accommodate for
those plugins that offer different maps having different
capabilities.
This is then used to properly push the min/max zoom levels
for each map type in our OSM plugin.
Autotests are included.
Change-Id: I48532da77ffb3eaf2e752561395945c3a2c21985
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
Diffstat (limited to 'src/location/maps/qgeomap_p_p.h')
-rw-r--r-- | src/location/maps/qgeomap_p_p.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/location/maps/qgeomap_p_p.h b/src/location/maps/qgeomap_p_p.h index 399fd75b..ec498484 100644 --- a/src/location/maps/qgeomap_p_p.h +++ b/src/location/maps/qgeomap_p_p.h @@ -51,6 +51,8 @@ #include <QtLocation/private/qgeocameradata_p.h> #include <QtLocation/private/qgeomaptype_p.h> #include <QtLocation/private/qgeoprojection_p.h> +#include <QtLocation/private/qgeomap_p.h> +#include <QtLocation/private/qgeocameracapabilities_p.h> #include <QtCore/private/qobject_p.h> #include <QtCore/QSize> #include <QtCore/QList> @@ -73,6 +75,8 @@ public: virtual ~QGeoMapPrivate(); const QGeoProjection *geoProjection() const; + void setCameraCapabilities(const QGeoCameraCapabilities &cameraCapabilities); + const QGeoCameraCapabilities &cameraCapabilities() const; protected: /* Hooks into the actual map implementations */ virtual void addParameter(QGeoMapParameter *param); @@ -94,6 +98,7 @@ protected: QGeoMapType m_activeMapType; QList<QGeoMapParameter *> m_mapParameters; QList<QDeclarativeGeoMapItemBase *> m_mapItems; + QGeoCameraCapabilities m_cameraCapabilities; }; QT_END_NAMESPACE |