summaryrefslogtreecommitdiffstats
path: root/core/gpslocation.h
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2019-09-27 16:26:54 -0700
committerGravatar Dirk Hohndel <dirk@hohndel.org>2019-09-27 16:26:58 -0700
commit9ae7040a91c3e3e0606d7abe085ef6da47efd6d2 (patch)
treede120b115df95fb96d945581aca41cd8c760263c /core/gpslocation.h
parent400b218f769320221567b7b66f39c33126a7d2e1 (diff)
downloadsubsurface-9ae7040a91c3e3e0606d7abe085ef6da47efd6d2.tar.gz
Revert the singleton PR
It turns out that this isn't working the way it was intended to. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'core/gpslocation.h')
-rw-r--r--core/gpslocation.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/core/gpslocation.h b/core/gpslocation.h
index 60e16e186..02377bfca 100644
--- a/core/gpslocation.h
+++ b/core/gpslocation.h
@@ -24,6 +24,9 @@ class GpsLocation : public QObject {
Q_OBJECT
public:
GpsLocation(void (*showMsgCB)(const char *msg), QObject *parent);
+ ~GpsLocation();
+ static GpsLocation *instance();
+ static bool hasInstance();
bool applyLocations();
int getGpsNum() const;
bool hasLocationsSource();
@@ -40,6 +43,7 @@ private:
QNetworkReply *reply;
QString userAgent;
void (*showMessageCB)(const char *msg);
+ static GpsLocation *m_Instance;
bool waitingForPosition;
QMap<qint64, gpsTracker> m_trackers;
QList<gpsTracker> m_deletedTrackers;