aboutsummaryrefslogtreecommitdiffstats
path: root/mobile-widgets
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2018-08-06 18:37:47 -0700
committerGravatar Dirk Hohndel <dirk@hohndel.org>2018-08-11 11:14:22 -0700
commit76e81e5d5387bda41717c23f4a54f6d6370599c2 (patch)
tree93e8fb9d36ca4e49a07d48691d0fb20d104ec327 /mobile-widgets
parent0b242bcaca6a6cb1f0ae734f8ea1c1b22a01648b (diff)
downloadsubsurface-76e81e5d5387bda41717c23f4a54f6d6370599c2.tar.gz
QML UI: create separate function to show download page
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'mobile-widgets')
-rw-r--r--mobile-widgets/qml/DiveList.qml8
1 files changed, 6 insertions, 2 deletions
diff --git a/mobile-widgets/qml/DiveList.qml b/mobile-widgets/qml/DiveList.qml
index af7537064..54f657a30 100644
--- a/mobile-widgets/qml/DiveList.qml
+++ b/mobile-widgets/qml/DiveList.qml
@@ -405,14 +405,18 @@ Kirigami.ScrollablePage {
}
}
+ function showDownloadPage() {
+ downloadFromDc.dcImportModel.clearTable()
+ stackView.push(downloadFromDc)
+ }
+
property QtObject downloadFromDCAction: Kirigami.Action {
icon {
name: ":/icons/downloadDC"
color: subsurfaceTheme.primaryColor
}
onTriggered: {
- downloadFromDc.dcImportModel.clearTable()
- stackView.push(downloadFromDc)
+ showDownloadPage()
}
}