summaryrefslogtreecommitdiffstats
path: root/mobile-widgets/qml/DiveDetails.qml
diff options
context:
space:
mode:
Diffstat (limited to 'mobile-widgets/qml/DiveDetails.qml')
-rw-r--r--mobile-widgets/qml/DiveDetails.qml9
1 files changed, 9 insertions, 0 deletions
diff --git a/mobile-widgets/qml/DiveDetails.qml b/mobile-widgets/qml/DiveDetails.qml
index 2de542b6e..5a320f055 100644
--- a/mobile-widgets/qml/DiveDetails.qml
+++ b/mobile-widgets/qml/DiveDetails.qml
@@ -42,6 +42,7 @@ Kirigami.Page {
target: diveDetailsPage;
actions {
right: deleteAction
+ left: diveDetailsListView.currentItem.modelData.dive.gps !== "" ? mapAction : null
}
}
PropertyChanges { target: detailsEditScroll; opened: false }
@@ -73,6 +74,14 @@ Kirigami.Page {
}
}
+ property QtObject mapAction: Action {
+ text: "Show on map"
+ iconName: "gps"
+ onTriggered: {
+ showMap(diveDetailsListView.currentItem.modelData.dive.gps)
+ }
+ }
+
actions.main: Action {
iconName: state !== "view" ? "document-save" : "document-edit"
onTriggered: {