diff options
author | Dirk Hohndel <dirk@hohndel.org> | 2016-04-01 22:31:33 -0500 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2016-04-01 22:31:33 -0500 |
commit | 48362ae11a175ce64518e1203b893b0d401fec5a (patch) | |
tree | e0e98693fe525219b4acf619ae1dd0c20e76172b | |
parent | 7d62ce5295570f1aa3af09c6f4d89d1f9d5c2c62 (diff) | |
download | subsurface-48362ae11a175ce64518e1203b893b0d401fec5a.tar.gz |
QML UI: when on the dive list, action button now offers add dive
This seems like a useful default action when people are looking at the dive
list (and it's a request from a user to have this as a button instead of just
via the menu).
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
-rw-r--r-- | qt-mobile/qml/DiveList.qml | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/qt-mobile/qml/DiveList.qml b/qt-mobile/qml/DiveList.qml index 042376c37..d7fb5fdca 100644 --- a/qt-mobile/qml/DiveList.qml +++ b/qt-mobile/qml/DiveList.qml @@ -171,7 +171,7 @@ Kirigami.ScrollablePage { if (visible) { page.mainAction = page.saveAction } else { - page.mainAction = null + page.mainAction = page.addDiveAction } } @@ -215,6 +215,12 @@ Kirigami.ScrollablePage { } } + property QtObject addDiveAction: Action { + iconName: "list-add" + onTriggered: { + startAddDive() + } + } property QtObject saveAction: Action { iconName: "document-save" |