Commit 9ad555d0 authored by Don Gagne's avatar Don Gagne

parent 75f3cba8
...@@ -310,6 +310,7 @@ FlightMap { ...@@ -310,6 +310,7 @@ FlightMap {
} }
property bool inGotoFlightMode: _activeVehicle ? _activeVehicle.flightMode === _activeVehicle.gotoFlightMode : false property bool inGotoFlightMode: _activeVehicle ? _activeVehicle.flightMode === _activeVehicle.gotoFlightMode : false
property var activeVehicle: _activeVehicle
onInGotoFlightModeChanged: { onInGotoFlightModeChanged: {
if (!inGotoFlightMode && visible) { if (!inGotoFlightMode && visible) {
...@@ -318,6 +319,12 @@ FlightMap { ...@@ -318,6 +319,12 @@ FlightMap {
} }
} }
onActiveVehicleChanged: {
if (!_activeVehicle) {
visible = false
}
}
function show(coord) { function show(coord) {
gotoLocationItem.coordinate = coord gotoLocationItem.coordinate = coord
gotoLocationItem.visible = true gotoLocationItem.visible = true
...@@ -345,9 +352,16 @@ FlightMap { ...@@ -345,9 +352,16 @@ FlightMap {
property alias center: _mapCircle.center property alias center: _mapCircle.center
property alias clockwiseRotation: _mapCircle.clockwiseRotation property alias clockwiseRotation: _mapCircle.clockwiseRotation
property var activeVehicle: _activeVehicle
readonly property real defaultRadius: 30 readonly property real defaultRadius: 30
onActiveVehicleChanged: {
if (!_activeVehicle) {
visible = false
}
}
function show(coord) { function show(coord) {
_mapCircle.radius.rawValue = defaultRadius _mapCircle.radius.rawValue = defaultRadius
orbitMapCircle.center = coord orbitMapCircle.center = coord
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment