diff options
author | Ivan Solovev <ivan.solovev@qt.io> | 2021-01-29 15:32:58 +0100 |
---|---|---|
committer | Ivan Solovev <ivan.solovev@qt.io> | 2021-02-03 12:20:29 +0100 |
commit | 84330ea286c0b6abeefccb42499b0838fc5ec40c (patch) | |
tree | 10c4743fe274526915ea56eef09fdd0622022b1c /src/plugins/position/serialnmea/qnmeasatelliteinfosource.cpp | |
parent | 6e20620fdc5a7e95410dfb740e9a09b0cab59930 (diff) | |
download | qtlocation-84330ea286c0b6abeefccb42499b0838fc5ec40c.tar.gz |
QtPositioning: add QObjectPrivate base for private classes
Refactor private classes of QGeoAreaMonitorSource, QGeoPositionInfoSource
and QGeoSatelliteInfoSource to inherit from QObjectPrivate.
This will help us to introduce new QProperty system for these classes.
Task-number: QTBUG-90491
Change-Id: I5774c8596372943ce595543c242c8e8c2405f647
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
Diffstat (limited to 'src/plugins/position/serialnmea/qnmeasatelliteinfosource.cpp')
-rw-r--r-- | src/plugins/position/serialnmea/qnmeasatelliteinfosource.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/plugins/position/serialnmea/qnmeasatelliteinfosource.cpp b/src/plugins/position/serialnmea/qnmeasatelliteinfosource.cpp index c33eb146..e08bc5e2 100644 --- a/src/plugins/position/serialnmea/qnmeasatelliteinfosource.cpp +++ b/src/plugins/position/serialnmea/qnmeasatelliteinfosource.cpp @@ -88,7 +88,7 @@ QGeoSatelliteInfoPrivate *QGeoSatelliteInfoPrivateNmea::clone() const typedef QGeoSatelliteInfoPrivate QGeoSatelliteInfoPrivateNmea; #endif -class QNmeaSatelliteInfoSourcePrivate : public QObject, public QGeoSatelliteInfoSourcePrivate +class QNmeaSatelliteInfoSourcePrivate : public QObject { Q_OBJECT public: @@ -488,14 +488,14 @@ void QNmeaSatelliteInfoSourcePrivate::timerEvent(QTimerEvent * /*event*/) // currently supports only realtime QNmeaSatelliteInfoSource::QNmeaSatelliteInfoSource(QObject *parent) -: QGeoSatelliteInfoSource(*new QNmeaSatelliteInfoSourcePrivate(this), parent) + : QGeoSatelliteInfoSource(parent), + d(new QNmeaSatelliteInfoSourcePrivate(this)) { - d = static_cast<QNmeaSatelliteInfoSourcePrivate *>(QGeoSatelliteInfoSourcePrivate::get(*this)); } QNmeaSatelliteInfoSource::~QNmeaSatelliteInfoSource() { - // d deleted in superclass destructor + delete d; } void QNmeaSatelliteInfoSource::setDevice(QIODevice *device) |