From 07512cb2c8ed6e6878ddb29e44219cb5d71eaf59 Mon Sep 17 00:00:00 2001 From: Dirk Hohndel Date: Mon, 13 Jun 2016 16:42:36 -0700 Subject: QML UI: allow entering the cloud PIN on the mobile UI Now the user doesn't need to do this on the desktop app anymore. Signed-off-by: Dirk Hohndel --- mobile-widgets/qml/CloudCredentials.qml | 14 ++++++++++++++ mobile-widgets/qml/main.qml | 2 ++ 2 files changed, 16 insertions(+) (limited to 'mobile-widgets/qml') diff --git a/mobile-widgets/qml/CloudCredentials.qml b/mobile-widgets/qml/CloudCredentials.qml index 1222dbb2b..7f1e0d986 100644 --- a/mobile-widgets/qml/CloudCredentials.qml +++ b/mobile-widgets/qml/CloudCredentials.qml @@ -16,6 +16,7 @@ Item { function saveCredentials() { manager.cloudUserName = login.text manager.cloudPassword = password.text + manager.cloudPin = pin.text manager.saveCloudCredentials() } @@ -76,6 +77,7 @@ Item { Qt.ImhNoAutoUppercase Layout.fillWidth: true } + GridLayout { columns: 2 @@ -90,6 +92,18 @@ Item { text: qsTr("Show password") } } + + Kirigami.Label { + text: qsTr("PIN") + visible: rootItem.showPin + } + StyledTextField { + id: pin + text: "" + Layout.fillWidth: true + visible: rootItem.showPin + } + Item { width: Kirigami.Units.gridUnit; height: width } } } diff --git a/mobile-widgets/qml/main.qml b/mobile-widgets/qml/main.qml index a855cdaf6..99c8dc27b 100644 --- a/mobile-widgets/qml/main.qml +++ b/mobile-widgets/qml/main.qml @@ -23,6 +23,8 @@ Kirigami.ApplicationWindow { property QtObject notification: null property bool showingDiveList: false property alias syncToCloud: manager.syncToCloud + property alias showPin: manager.showPin + onAccessingCloudChanged: { // >= 0 for updating cloud, -1 for hide, < -1 for local storage if (accessingCloud >= 0) { -- cgit v1.2.3-70-g09d2