summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorasanoaozora <fifitaneki@hotmail.com>2017-05-05 16:59:54 +0200
committerasanoaozora <fifitaneki@hotmail.com>2017-05-05 16:59:54 +0200
commitdd793749ccce49456df5ed1e0381e736bb664164 (patch)
treed9f7a7e39ca0dfa5f89bd8bdbd462c251a2b750e
parentb2ae83e4f345fdf3cb8de3ab52d578d84b79d483 (diff)
downloadnavigation-dd793749ccce49456df5ed1e0381e736bb664164.tar.gz
add 'back to current location' button to browse map
-rwxr-xr-xsrc/hmi/gimp/gdp-theme/800x480/NavigationAppBrowseMapScroll.xcfbin8053 -> 7968 bytes
-rw-r--r--src/hmi/qml/NavigationAppBrowseMap.qml16
2 files changed, 16 insertions, 0 deletions
diff --git a/src/hmi/gimp/gdp-theme/800x480/NavigationAppBrowseMapScroll.xcf b/src/hmi/gimp/gdp-theme/800x480/NavigationAppBrowseMapScroll.xcf
index 27f6842..a593b3a 100755
--- a/src/hmi/gimp/gdp-theme/800x480/NavigationAppBrowseMapScroll.xcf
+++ b/src/hmi/gimp/gdp-theme/800x480/NavigationAppBrowseMapScroll.xcf
Binary files differ
diff --git a/src/hmi/qml/NavigationAppBrowseMap.qml b/src/hmi/qml/NavigationAppBrowseMap.qml
index 0687b06..eb6518a 100644
--- a/src/hmi/qml/NavigationAppBrowseMap.qml
+++ b/src/hmi/qml/NavigationAppBrowseMap.qml
@@ -1026,6 +1026,7 @@ NavigationAppHMIMenu {
}
disabled:!(Genivi.route_calculated && !Genivi.guidance_activated);
+ visible:(Genivi.route_calculated && !Genivi.guidance_activated);
next:menub; prev:settings
}
@@ -1180,6 +1181,21 @@ NavigationAppHMIMenu {
onPressed: {Genivi.mapviewer_SetMapViewPan(dbusIf,Genivi.MAPVIEWER_PAN_START,map.width/2,map.height/2);}
onReleased: {Genivi.mapviewer_SetMapViewPan(dbusIf,Genivi.MAPVIEWER_PAN_END,map.width/2,map.height/2 - scroll.panY);}
}
+
+ StdButton {
+ source:StyleSheetScroll.backtoCurrentLocation[Constants.SOURCE]; x:StyleSheetScroll.backtoCurrentLocation[Constants.X]; y:StyleSheetScroll.backtoCurrentLocation[Constants.Y]; width:StyleSheetScroll.backtoCurrentLocation[Constants.WIDTH]; height:StyleSheetScroll.backtoCurrentLocation[Constants.HEIGHT];
+ id:backtoCurrentLocation; next:scrollup; prev:scrollright;
+ onClicked: {
+ if (Genivi.data['display_on_map']==='show_current_position') {
+ Genivi.mapviewer_SetTargetPoint(dbusIf,Genivi.data['current_position']['lat'],Genivi.data['current_position']['lon'],Genivi.data['current_position']['alt']);
+ } else {
+ if (Genivi.data['display_on_map']==='show_position') {
+ Genivi.mapviewer_SetTargetPoint(dbusIf,Genivi.data['position']['lat'],Genivi.data['position']['lon'],Genivi.data['position']['alt']);
+ }
+ }
+ }
+ }
+
}
}