summaryrefslogtreecommitdiffstats
path: root/app
diff options
context:
space:
mode:
authorScott Murray <scott.murray@konsulko.com>2020-01-03 11:23:36 -0500
committerScott Murray <scott.murray@konsulko.com>2020-01-03 11:30:17 -0500
commite878fbc2113960975b8488643f493a5f1c48b9e6 (patch)
tree9d1cf1ce4991cc2b6bd4a016eb0cc7ee7bed50a6 /app
parentc285683b960ccfadd35f62c74c14871c61e4d24c (diff)
Further re-center behavior improvementsicefish_8.99.5icefish/8.99.58.99.5
Add logic to enable re-center button when the view is centered but zoomed in/out, for consistency. Additionally, re-center when routing is started to improve user experience. Bug-AGL: SPEC-3081 Signed-off-by: Scott Murray <scott.murray@konsulko.com> Change-Id: Ifed6702ee5f1d1db266c612a23fea51661c2a51b
Diffstat (limited to 'app')
-rw-r--r--app/BtnEnlarge.qml5
-rw-r--r--app/BtnGuidance.qml2
-rw-r--r--app/BtnShrink.qml5
3 files changed, 10 insertions, 2 deletions
diff --git a/app/BtnEnlarge.qml b/app/BtnEnlarge.qml
index 032dc14..cc158ad 100644
--- a/app/BtnEnlarge.qml
+++ b/app/BtnEnlarge.qml
@@ -7,8 +7,11 @@ Item {
height: 100
function zoomUp() {
- map.zoomLevel += 1
+ map.zoomLevel += 1
+ if(map.zoomLevel != default_zoom_level) {
+ btn_present_position.state = "Optional"
}
+ }
onClicked: { zoomUp() }
diff --git a/app/BtnGuidance.qml b/app/BtnGuidance.qml
index e5df9c3..bebb53b 100644
--- a/app/BtnGuidance.qml
+++ b/app/BtnGuidance.qml
@@ -31,6 +31,8 @@ Item {
btn_present_position.state = "Flowing"
btn_guidance.sts_guide = 2
btn_guidance.state = "onGuide"
+ map.zoomLevel = default_zoom_level
+ map.bearing = 0
}
function discardWaypoints(startFromCurrentPosition) {
diff --git a/app/BtnShrink.qml b/app/BtnShrink.qml
index da9700e..23859dc 100644
--- a/app/BtnShrink.qml
+++ b/app/BtnShrink.qml
@@ -8,8 +8,11 @@ Item {
height: 100
function zoomDown() {
- map.zoomLevel -= 1
+ map.zoomLevel -= 1
+ if(map.zoomLevel != default_zoom_level) {
+ btn_present_position.state = "Optional"
}
+ }
onClicked: { zoomDown() }