diff options
author | Dirk Hohndel <dirk@hohndel.org> | 2016-06-13 16:41:26 -0700 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2016-06-13 16:41:26 -0700 |
commit | 5fa965df54c1ab7f881271e0dad2b6dfa6f253ed (patch) | |
tree | 432403c86bf9f212af422b0f8138f8b186c0eb80 /mobile-widgets/qmlmanager.h | |
parent | d2f9803883ff1453e71a29e358fd5368f650fb62 (diff) | |
download | subsurface-5fa965df54c1ab7f881271e0dad2b6dfa6f253ed.tar.gz |
QML UI: prepare to enter the cloud PIN on mobile UI
This just creates the properties to connect QML and C++ code.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'mobile-widgets/qmlmanager.h')
-rw-r--r-- | mobile-widgets/qmlmanager.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/mobile-widgets/qmlmanager.h b/mobile-widgets/qmlmanager.h index 10ff0ba51..b7be359ed 100644 --- a/mobile-widgets/qmlmanager.h +++ b/mobile-widgets/qmlmanager.h @@ -15,6 +15,7 @@ class QMLManager : public QObject { Q_ENUMS(credentialStatus_t) Q_PROPERTY(QString cloudUserName READ cloudUserName WRITE setCloudUserName NOTIFY cloudUserNameChanged) Q_PROPERTY(QString cloudPassword READ cloudPassword WRITE setCloudPassword NOTIFY cloudPasswordChanged) + Q_PROPERTY(QString cloudPin READ cloudPin WRITE setCloudPin NOTIFY cloudPinChanged) Q_PROPERTY(QString logText READ logText WRITE setLogText NOTIFY logTextChanged) Q_PROPERTY(bool locationServiceEnabled READ locationServiceEnabled WRITE setLocationServiceEnabled NOTIFY locationServiceEnabledChanged) Q_PROPERTY(bool locationServiceAvailable READ locationServiceAvailable WRITE setLocationServiceAvailable NOTIFY locationServiceAvailableChanged) @@ -32,6 +33,7 @@ class QMLManager : public QObject { Q_PROPERTY(QStringList suitInit READ suitInit CONSTANT) Q_PROPERTY(QStringList buddyInit READ buddyInit CONSTANT) Q_PROPERTY(QStringList divemasterInit READ divemasterInit CONSTANT) + Q_PROPERTY(bool showPin READ showPin WRITE setShowPin NOTIFY showPinChanged) public: QMLManager(); @@ -54,6 +56,9 @@ public: QString cloudPassword() const; void setCloudPassword(const QString &cloudPassword); + QString cloudPin() const; + void setCloudPin(const QString &cloudPin); + bool locationServiceEnabled() const; void setLocationServiceEnabled(bool locationServiceEnable); @@ -104,6 +109,9 @@ public: QStringList buddyInit() const; QStringList divemasterInit() const; + bool showPin() const; + void setShowPin(bool enable); + public slots: void applicationStateChanged(Qt::ApplicationState state); void savePreferences(); @@ -153,6 +161,7 @@ public slots: private: QString m_cloudUserName; QString m_cloudPassword; + QString m_cloudPin; QString m_ssrfGpsWebUserid; QString m_startPageText; QString m_logText; @@ -182,10 +191,12 @@ private: bool checkDuration(DiveObjectHelper *myDive, struct dive *d, QString duration); bool checkDepth(DiveObjectHelper *myDive, struct dive *d, QString depth); bool currentGitLocalOnly; + bool m_showPin; signals: void cloudUserNameChanged(); void cloudPasswordChanged(); + void cloudPinChanged(); void locationServiceEnabledChanged(); void locationServiceAvailableChanged(); void verboseEnabledChanged(); @@ -200,6 +211,7 @@ signals: void syncToCloudChanged(); void updateSelectedDiveChanged(); void selectedDiveTimestampChanged(); + void showPinChanged(); void sendScreenChanged(QScreen *screen); }; |