diff options
author | Aaron McCarthy <aaron.mccarthy@nokia.com> | 2012-06-06 09:19:09 +1000 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-06-07 03:05:34 +0200 |
commit | 5e8bdd51c889403db99d0dbad908b6e862252a70 (patch) | |
tree | 7dc34fce9b8996b8a380d7719b28dee9842ef5f9 /src/location/maps/qgeotiledmapreply_p.h | |
parent | 702a9d73fa145fd107c8a3f03d68d93b6968af77 (diff) |
Remove Maps from public C++ API.
The preliminary C++ Maps API was exposed to provide an interface
between the QML plugin and the geo services plugins. Mark it as
private API for now as it is likely to change when the full C++ API is
developed.
Mapping functionality is currently only available through QML.
Change-Id: Id16e0f1a2165c70192047dffa40e69ab1f29ba69
Reviewed-by: Alex Wilson <alex.wilson@nokia.com>
Diffstat (limited to 'src/location/maps/qgeotiledmapreply_p.h')
-rw-r--r-- | src/location/maps/qgeotiledmapreply_p.h | 74 |
1 files changed, 57 insertions, 17 deletions
diff --git a/src/location/maps/qgeotiledmapreply_p.h b/src/location/maps/qgeotiledmapreply_p.h index 8584465e..8544227f 100644 --- a/src/location/maps/qgeotiledmapreply_p.h +++ b/src/location/maps/qgeotiledmapreply_p.h @@ -39,8 +39,8 @@ ** ****************************************************************************/ -#ifndef QGEOTILEDMAPREPLY_P_H -#define QGEOTILEDMAPREPLY_P_H +#ifndef QGEOTILEDMAPREPLY_H +#define QGEOTILEDMAPREPLY_H // // W A R N I N G @@ -53,28 +53,68 @@ // We mean it. // -#include "qgeotiledmapreply.h" -#include "qgeotilespec.h" +#include <QtLocation/qlocationglobal.h> + +#include <QObject> + +QT_BEGIN_HEADER QT_BEGIN_NAMESPACE -class QGeoTiledMapReplyPrivate + + +class QGeoTileSpec; +class QGeoTiledMapReplyPrivate; + +class Q_LOCATION_EXPORT QGeoTiledMapReply : public QObject { + Q_OBJECT + public: - QGeoTiledMapReplyPrivate(const QGeoTileSpec &spec); - QGeoTiledMapReplyPrivate(QGeoTiledMapReply::Error error, const QString &errorString); - ~QGeoTiledMapReplyPrivate(); - - QGeoTiledMapReply::Error error; - QString errorString; - bool isFinished; - bool isCached; - - QGeoTileSpec spec; - QByteArray mapImageData; - QString mapImageFormat; + enum Error { + NoError, + CommunicationError, + ParseError, + UnknownError + }; + + QGeoTiledMapReply(const QGeoTileSpec &spec, QObject *parent = 0); + QGeoTiledMapReply(Error error, const QString &errorString, QObject *parent = 0); + virtual ~QGeoTiledMapReply(); + + bool isFinished() const; + Error error() const; + QString errorString() const; + + bool isCached() const; + + QGeoTileSpec tileSpec() const; + + QByteArray mapImageData() const; + QString mapImageFormat() const; + + virtual void abort(); + +Q_SIGNALS: + void finished(); + void error(QGeoTiledMapReply::Error error, const QString &errorString = QString()); + +protected: + void setError(Error error, const QString &errorString); + void setFinished(bool finished); + + void setCached(bool cached); + + void setMapImageData(const QByteArray &data); + void setMapImageFormat(const QString &format); + +private: + QGeoTiledMapReplyPrivate *d_ptr; + Q_DISABLE_COPY(QGeoTiledMapReply) }; QT_END_NAMESPACE +QT_END_HEADER + #endif |