diff options
Diffstat (limited to 'mobile-widgets/qml/main.qml')
| -rw-r--r-- | mobile-widgets/qml/main.qml | 24 |
1 files changed, 23 insertions, 1 deletions
diff --git a/mobile-widgets/qml/main.qml b/mobile-widgets/qml/main.qml index 4f5344275..837b29b59 100644 --- a/mobile-widgets/qml/main.qml +++ b/mobile-widgets/qml/main.qml @@ -88,6 +88,9 @@ Kirigami.ApplicationWindow { for (var i=pageStack.depth; i>1; i--) { pageStack.pop() } + if (pageStack.currentItem !== diveList) { + showDiveList() + } detailsWindow.endEditMode() } @@ -96,6 +99,15 @@ Kirigami.ApplicationWindow { } function showPage(page) { + if (page === statistics) { + manager.appendTextToLog("switching to statistics page, clearing out stack") + pageStack.clear() + } + if (pageStack.currentItem === statistics) { + manager.appendTextToLog("switching away from statistics page, clearing out stack") + pageStack.clear() + } + if (page !== mapPage) hackToOpenMap = 0 // we really want a different page if (globalDrawer.drawerOpen) @@ -441,6 +453,12 @@ if you have network connectivity and want to sync your data to cloud storage."), } }, Kirigami.Action { + text: qsTr("Statistics") + onTriggered: { + showPage(statistics) + } + }, + Kirigami.Action { icon { name: ":/icons/ic_settings.svg" } @@ -859,9 +877,13 @@ if you have network connectivity and want to sync your data to cloud storage."), visible: false } + StatisticsPage { + id: statistics + visible: false + } + Settings { id: settingsWindow - visible: false } CopySettings { |