From 783332561a433e8ff8be8b0bceb25a051967d3cf Mon Sep 17 00:00:00 2001 From: jan Iversen Date: Sat, 28 Dec 2019 17:30:14 +0100 Subject: mobile-widgets: credentialStatus() -> cloud_verification_status() Replace all credentialStatus() with cloud_verification_status() Where both prefs.credentialStatus and PrefCloudStorage.cloud_verification_status are being set, remove prefs.credentialStatus. These replacements are valid since credentialStatus() is a simple envelope over cloud_verification_status(). Also remove qmlPrefs::credentialStatus() from qmlPrefs (mostly to ensure no replacements was forgotten). Signed-off-by: Jan Iversen Signed-off-by: Dirk Hohndel --- mobile-widgets/qml/CloudCredentials.qml | 4 ++-- mobile-widgets/qml/Settings.qml | 3 +-- 2 files changed, 3 insertions(+), 4 deletions(-) (limited to 'mobile-widgets/qml') diff --git a/mobile-widgets/qml/CloudCredentials.qml b/mobile-widgets/qml/CloudCredentials.qml index 12f8a53d1..6bed7b1f7 100644 --- a/mobile-widgets/qml/CloudCredentials.qml +++ b/mobile-widgets/qml/CloudCredentials.qml @@ -110,7 +110,6 @@ Item { text: qsTr("Cancel") onClicked: { PrefCloudStorage.cloud_verification_status = CloudStatus.CS_UNKNOWN - prefs.cloudCredentials = CloudStatus.CS_UNKNOWN manager.startPageText = qsTr("Check credentials..."); prefs.showPin = false; } @@ -140,7 +139,8 @@ Item { onClicked: { manager.setGitLocalOnly(true) PrefCloudStorage.cloud_auto_sync = false - prefs.credentialStatus = CloudStatus.CS_NOCLOUD + prefs.oldStatus = PrefCloudStorage.cloud_verification_status + PrefCloudStorage.cloud_verification_status = CloudStatus.CS_NOCLOUD manager.saveCloudCredentials("", "", "") manager.openNoCloudRepo() } diff --git a/mobile-widgets/qml/Settings.qml b/mobile-widgets/qml/Settings.qml index ae5f95751..03ffa13a9 100644 --- a/mobile-widgets/qml/Settings.qml +++ b/mobile-widgets/qml/Settings.qml @@ -55,7 +55,6 @@ Kirigami.ScrollablePage { text: qsTr("Change") onClicked: { PrefCloudStorage.cloud_verification_status = CloudStatus.CS_UNKNOWN - prefs.credentialStatus = CloudStatus.CS_UNKNOWN manager.startPageText = qsTr("Starting..."); prefs.showPin = false; } @@ -68,7 +67,7 @@ Kirigami.ScrollablePage { color: subsurfaceTheme.textColor } Controls.Label { - text: describe[prefs.credentialStatus] + text: describe[PrefCloudStorage.cloud_verification_status] font.pointSize: subsurfaceTheme.regularPointSize Layout.preferredWidth: gridWidth * 0.60 Layout.preferredHeight: Kirigami.Units.gridUnit * 1.5 -- cgit v1.2.3-70-g09d2