mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
QML UI: make return to dive list work when entering credentials
If the user tapped on the "Cloud credentials" menu and wants to go back to the dive list (by selecting that option from the menu), allow them to do so if they previously had valid credentials. This allows them to go back to the dive list even on a device without a back button like an iOS device. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
8dcb6fa25c
commit
4f935595d9
1 changed files with 7 additions and 0 deletions
|
@ -46,6 +46,13 @@ MobileComponents.ApplicationWindow {
|
|||
Action {
|
||||
text: "Dive list"
|
||||
onTriggered: {
|
||||
if (manager.credentialStatus == QMLManager.UNKNOWN) {
|
||||
// the user has asked to change credentials - if the credentials before that
|
||||
// were valid, go back to dive list
|
||||
if (oldStatus == QMLManager.VALID || oldStatus == QMLManager.VALID_EMAIL) {
|
||||
manager.credentialStatus = oldStatus
|
||||
}
|
||||
}
|
||||
returnTopPage()
|
||||
globalDrawer.close()
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue