summaryrefslogtreecommitdiffstats
path: root/mobile-widgets/qml/GpsList.qml
diff options
context:
space:
mode:
authorGravatar Lubomir I. Ivanov <neolit123@gmail.com>2018-03-08 22:22:35 +0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2018-03-11 11:40:12 -0700
commit68da4de643d616a52990d7c109b33dca14ff61f3 (patch)
tree983088f6898375195f657727a8455f1e9417c1c5 /mobile-widgets/qml/GpsList.qml
parent61c90efc6b757e9ca1c6910f5c112275fba0f53c (diff)
downloadsubsurface-68da4de643d616a52990d7c109b33dca14ff61f3.tar.gz
main.qml: modify showMap() to not accept location
showMap() uses a location to open Google Maps in a browser. Make showMap() a generic function to push the mapPage on the view stack. Update the calls to this function from child widgets and pages. Also either call mapPage.centerOnLocation() or mapPage.centerOnDiveSiteUUID() depending if the caller wants the map to center on a dive site or on map coordinates. Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Diffstat (limited to 'mobile-widgets/qml/GpsList.qml')
-rw-r--r--mobile-widgets/qml/GpsList.qml3
1 files changed, 2 insertions, 1 deletions
diff --git a/mobile-widgets/qml/GpsList.qml b/mobile-widgets/qml/GpsList.qml
index 51025299f..ea5098943 100644
--- a/mobile-widgets/qml/GpsList.qml
+++ b/mobile-widgets/qml/GpsList.qml
@@ -86,7 +86,8 @@ Kirigami.ScrollablePage {
name: "gps"
}
onTriggered: {
- showMap(latitude + " " + longitude)
+ showMap()
+ mapPage.centerOnLocation(latitude, longitude)
}
}