diff options
author | Dirk Hohndel <dirk@hohndel.org> | 2015-11-14 09:10:06 -0800 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2015-11-14 09:10:06 -0800 |
commit | 76d07635270bb3068b7d9a559b481d3c094f0d7b (patch) | |
tree | cd507fe34e03b8c5cc2c10e9d991a50f44635d9e /qt-mobile/qmlmanager.h | |
parent | 24404a401d5a21134b153000fffc74bd429a0631 (diff) | |
download | subsurface-76d07635270bb3068b7d9a559b481d3c094f0d7b.tar.gz |
Location service: make distance and time threshold configurable
Right now the distance is always in meters, the mobile app doesn't deal
with units at all, anyway.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-mobile/qmlmanager.h')
-rw-r--r-- | qt-mobile/qmlmanager.h | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/qt-mobile/qmlmanager.h b/qt-mobile/qmlmanager.h index b71dcfec5..1d5f8e412 100644 --- a/qt-mobile/qmlmanager.h +++ b/qt-mobile/qmlmanager.h @@ -17,6 +17,8 @@ class QMLManager : public QObject Q_PROPERTY(QString logText READ logText WRITE setLogText NOTIFY logTextChanged) Q_PROPERTY(bool locationServiceEnabled READ locationServiceEnabled WRITE setLocationServiceEnabled NOTIFY locationServiceEnabledChanged) Q_PROPERTY(QString ssrfGpsWebUserid READ ssrfGpsWebUserid WRITE setSsrfGpsWebUserid NOTIFY ssrfGpsWebUseridChanged) + Q_PROPERTY(int distanceThreshold READ distanceThreshold WRITE setDistanceThreshold NOTIFY distanceThresholdChanged) + Q_PROPERTY(int timeThreshold READ timeThreshold WRITE setTimeThreshold NOTIFY timeThresholdChanged) public: QMLManager(); ~QMLManager(); @@ -27,15 +29,21 @@ public: QString cloudPassword() const; void setCloudPassword(const QString &cloudPassword); - QString ssrfGpsWebUserid() const; - void setSsrfGpsWebUserid(const QString &userid); - bool saveCloudPassword() const; void setSaveCloudPassword(bool saveCloudPassword); + QString ssrfGpsWebUserid() const; + void setSsrfGpsWebUserid(const QString &userid); + bool locationServiceEnabled() const; void setLocationServiceEnabled(bool locationServiceEnable); + int distanceThreshold() const; + void setDistanceThreshold(int distance); + + int timeThreshold() const; + void setTimeThreshold(int time); + QString logText() const; void setLogText(const QString &logText); void appendTextToLog(const QString &newText); @@ -57,6 +65,8 @@ private: bool m_saveCloudPassword; QString m_logText; bool m_locationServiceEnabled; + int m_distanceThreshold; + int m_timeThreshold; GpsLocation *locationProvider; signals: @@ -66,6 +76,8 @@ signals: void saveCloudPasswordChanged(); void locationServiceEnabledChanged(); void logTextChanged(); + void timeThresholdChanged(); + void distanceThresholdChanged(); }; #endif |