mirror of
https://github.com/subsurface/subsurface.git
synced 2024-11-28 05:00:20 +00:00
mobile UI/login: remove startpage dependency in divelist
DiveList should not depend on StartPage, so remove references to startPage. Signed-off-by: Jan Iversen <jani@apache.org> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
b83dcc4b25
commit
11810d5d06
1 changed files with 5 additions and 14 deletions
|
@ -499,8 +499,6 @@ Kirigami.ScrollablePage {
|
||||||
ListView {
|
ListView {
|
||||||
id: diveListView
|
id: diveListView
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
opacity: 1.0 - startPage.opacity
|
|
||||||
visible: opacity > 0
|
|
||||||
model: diveListModel
|
model: diveListModel
|
||||||
currentIndex: -1
|
currentIndex: -1
|
||||||
delegate: diveDelegate
|
delegate: diveDelegate
|
||||||
|
@ -571,19 +569,12 @@ Kirigami.ScrollablePage {
|
||||||
}
|
}
|
||||||
|
|
||||||
onBackRequested: {
|
onBackRequested: {
|
||||||
if (startPage.visible && diveListView.count > 0 &&
|
if (Qt.platform.os != "ios")
|
||||||
prefs.credentialStatus !== CloudStatus.CS_INCORRECT_USER_PASSWD) {
|
|
||||||
prefs.credentialStatus = oldStatus
|
|
||||||
event.accepted = true;
|
|
||||||
}
|
|
||||||
if (!startPage.visible) {
|
|
||||||
if (Qt.platform.os != "ios") {
|
|
||||||
manager.quit()
|
manager.quit()
|
||||||
}
|
|
||||||
// let's make sure Kirigami doesn't quit on our behalf
|
// let's make sure Kirigami doesn't quit on our behalf
|
||||||
event.accepted = true
|
event.accepted = true
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
function setCurrentDiveListIndex(idx, noScroll) {
|
function setCurrentDiveListIndex(idx, noScroll) {
|
||||||
// pick the dive in the dive list and make sure its trip is expanded
|
// pick the dive in the dive list and make sure its trip is expanded
|
||||||
|
|
Loading…
Reference in a new issue