diff options
Diffstat (limited to 'src/location/maps')
-rw-r--r-- | src/location/maps/qgeomaptype.cpp | 20 | ||||
-rw-r--r-- | src/location/maps/qgeomaptype_p.h | 3 | ||||
-rw-r--r-- | src/location/maps/qgeomaptype_p_p.h | 5 |
3 files changed, 19 insertions, 9 deletions
diff --git a/src/location/maps/qgeomaptype.cpp b/src/location/maps/qgeomaptype.cpp index b4efa1d9..34781451 100644 --- a/src/location/maps/qgeomaptype.cpp +++ b/src/location/maps/qgeomaptype.cpp @@ -46,8 +46,8 @@ QGeoMapType::QGeoMapType(const QGeoMapType &other) : d_ptr(other.d_ptr) {} QGeoMapType::QGeoMapType(QGeoMapType::MapStyle style, const QString &name, - const QString &description, bool mobile, bool night, int mapId) -: d_ptr(new QGeoMapTypePrivate(style, name, description, mobile, night, mapId)) + const QString &description, bool mobile, bool night, int mapId, QByteArray pluginName) +: d_ptr(new QGeoMapTypePrivate(style, name, description, mobile, night, mapId, pluginName)) { } @@ -102,6 +102,11 @@ int QGeoMapType::mapId() const return d_ptr->mapId_; } +QByteArray QGeoMapType::pluginName() const +{ + return d_ptr->pluginName_; +} + QGeoMapTypePrivate::QGeoMapTypePrivate() : style_(QGeoMapType::NoMap), mobile_(false), night_(false), mapId_(0) { @@ -109,15 +114,15 @@ QGeoMapTypePrivate::QGeoMapTypePrivate() QGeoMapTypePrivate::QGeoMapTypePrivate(const QGeoMapTypePrivate &other) : QSharedData(other), style_(other.style_), name_(other.name_), description_(other.description_), - mobile_(other.mobile_), night_(other.night_), mapId_(other.mapId_) + mobile_(other.mobile_), night_(other.night_), mapId_(other.mapId_), pluginName_(other.pluginName_) { } QGeoMapTypePrivate::QGeoMapTypePrivate(QGeoMapType::MapStyle style, const QString &name, const QString &description, bool mobile, bool night, - int mapId) + int mapId, QByteArray pluginName) : style_(style), name_(name), description_(description), mobile_(mobile), night_(night), - mapId_(mapId) + mapId_(mapId), pluginName_(pluginName) { } @@ -127,8 +132,9 @@ QGeoMapTypePrivate::~QGeoMapTypePrivate() bool QGeoMapTypePrivate::operator==(const QGeoMapTypePrivate &other) const { - return style_ == other.style_ && name_ == other.name_ && description_ == other.description_ && - mobile_ == other.mobile_ && night_ == other.night_ && mapId_ == other.mapId_; + return pluginName_ == other.pluginName_ && style_ == other.style_ && name_ == other.name_ && + description_ == other.description_ && mobile_ == other.mobile_ && night_ == other.night_ && + mapId_ == other.mapId_; } QT_END_NAMESPACE diff --git a/src/location/maps/qgeomaptype_p.h b/src/location/maps/qgeomaptype_p.h index f26471f4..4b5cb0d0 100644 --- a/src/location/maps/qgeomaptype_p.h +++ b/src/location/maps/qgeomaptype_p.h @@ -77,7 +77,7 @@ public: QGeoMapType(); QGeoMapType(const QGeoMapType &other); QGeoMapType(MapStyle style, const QString &name, const QString &description, bool mobile, - bool night, int mapId); + bool night, int mapId, QByteArray pluginName); ~QGeoMapType(); QGeoMapType &operator = (const QGeoMapType &other); @@ -91,6 +91,7 @@ public: bool mobile() const; bool night() const; int mapId() const; + QByteArray pluginName() const; private: QSharedDataPointer<QGeoMapTypePrivate> d_ptr; diff --git a/src/location/maps/qgeomaptype_p_p.h b/src/location/maps/qgeomaptype_p_p.h index 2aafd37b..039c0962 100644 --- a/src/location/maps/qgeomaptype_p_p.h +++ b/src/location/maps/qgeomaptype_p_p.h @@ -50,6 +50,7 @@ #include <QMetaType> #include <QString> +#include <QByteArray> #include <QSharedData> #include "qgeomaptype_p.h" @@ -60,7 +61,8 @@ class QGeoMapTypePrivate : public QSharedData { public: QGeoMapTypePrivate(); - QGeoMapTypePrivate(QGeoMapType::MapStyle style, const QString &name, const QString &description, bool mobile, bool night, int mapId); + QGeoMapTypePrivate(QGeoMapType::MapStyle style, const QString &name, const QString &description, bool mobile, + bool night, int mapId, QByteArray pluginName); QGeoMapTypePrivate(const QGeoMapTypePrivate &other); ~QGeoMapTypePrivate(); @@ -74,6 +76,7 @@ public: bool mobile_; bool night_; int mapId_; + QByteArray pluginName_; }; QT_END_NAMESPACE |