diff options
author | philippe colliot <fifitaneki@hotmail.com> | 2017-07-12 14:05:11 +0200 |
---|---|---|
committer | philippe colliot <fifitaneki@hotmail.com> | 2017-07-12 14:05:11 +0200 |
commit | 1ea7ffcfd0185340d63e2154d533c667774c64d4 (patch) | |
tree | f5121071f5475e56ee422d9e7df38528c5dea00f /src/hmi/qml/NavigationAppBrowseMap.qml | |
parent | de34197e53425b1a12da795ba8e4dd4506687d7d (diff) | |
download | navigation-1ea7ffcfd0185340d63e2154d533c667774c64d4.tar.gz |
some improvements of the HMI to be tested
Diffstat (limited to 'src/hmi/qml/NavigationAppBrowseMap.qml')
-rw-r--r-- | src/hmi/qml/NavigationAppBrowseMap.qml | 38 |
1 files changed, 28 insertions, 10 deletions
diff --git a/src/hmi/qml/NavigationAppBrowseMap.qml b/src/hmi/qml/NavigationAppBrowseMap.qml index 27a851a..3c171a6 100644 --- a/src/hmi/qml/NavigationAppBrowseMap.qml +++ b/src/hmi/qml/NavigationAppBrowseMap.qml @@ -674,13 +674,20 @@ NavigationAppHMIMenu { } function toggleOrientation() - { - if (!orientation.status) { + { //N->D->B + if (orientation.status==0) { Genivi.mapviewer_SetCameraHeadingAngle(dbusIf,dltIf,0); + Genivi.mapviewer_SetMapViewPerspective(dbusIf,dltIf,Genivi.MAPVIEWER_2D); orientation.setState("D"); } else { - Genivi.mapviewer_SetCameraHeadingTrackUp(dbusIf,dltIf); - orientation.setState("N"); + if (orientation.status==1) { + Genivi.mapviewer_SetCameraHeadingTrackUp(dbusIf,dltIf); + Genivi.mapviewer_SetMapViewPerspective(dbusIf,dltIf,Genivi.MAPVIEWER_3D); + orientation.setState("B"); + } else{ + Genivi.mapviewer_SetMapViewPerspective(dbusIf,dltIf,Genivi.MAPVIEWER_2D); + orientation.setState("N"); + } } } @@ -1189,19 +1196,30 @@ NavigationAppHMIMenu { StdButton { x:StyleSheetCompass.directiondestination[Constants.X]; y:StyleSheetCompass.directiondestination[Constants.Y]; width:StyleSheetCompass.directiondestination[Constants.WIDTH]; height:StyleSheetCompass.directiondestination[Constants.HEIGHT]; id:orientation; next:zoomin; prev:menub; disabled:false; - source:StyleSheetCompass.directiondestination[Constants.SOURCE]; //todo call get status + source:StyleSheetCompass.directionnorth[Constants.SOURCE]; //todo call get status property int status: 0; function setState(name) - { - if (name=="D") + { //the state displayed is the current state + if (name=="N") { - status=1; + status=0; source=StyleSheetCompass.directionnorth[Constants.SOURCE]; } else { - status=0; - source=StyleSheetCompass.directiondestination[Constants.SOURCE]; + if (name=="D") + { + status=1; + source=StyleSheetCompass.directiondestination[Constants.SOURCE]; + } + else + { + if (name=="B") + { + status=2; + source=StyleSheetCompass.directionThreeD[Constants.SOURCE]; + } + } } } onClicked: |