Commit 33ee9833 authored by Don Gagne's avatar Don Gagne

Correct handling of fence visibility

parent 8eab3f6e
......@@ -110,7 +110,8 @@ FlightMap {
MapPolygon {
border.color: "#80FF0000"
border.width: 3
path: geoFenceController.polygonSupported ? geoFenceController.polygon.path : undefined
path: geoFenceController.polygon.path
visible: geoFenceController.fenceEnabled && geoFenceController.polygonSupported
}
// GeoFence circle
......@@ -118,15 +119,16 @@ FlightMap {
border.color: "#80FF0000"
border.width: 3
center: missionController.plannedHomePosition
radius: geoFenceController.circleSupported ? geoFenceController.circleRadius : 0
radius: (geoFenceController.fenceEnabled && geoFenceController.circleSupported) ? geoFenceController.circleRadius : 0
z: QGroundControl.zOrderMapItems
visible: geoFenceController.fenceEnabled && geoFenceController.circleSupported
}
// GeoFence breach return point
MapQuickItem {
anchorPoint: Qt.point(sourceItem.width / 2, sourceItem.height / 2)
coordinate: geoFenceController.breachReturnPoint
visible: geoFenceController.breachReturnSupported
visible: geoFenceController.fenceEnabled && geoFenceController.breachReturnSupported
sourceItem: MissionItemIndexLabel { label: "F" }
z: QGroundControl.zOrderMapItems
}
......
......@@ -786,8 +786,9 @@ QGCView {
MapPolygon {
border.color: "#80FF0000"
border.width: 3
path: geoFenceController.polygonSupported ? geoFenceController.polygon.path : undefined
path: geoFenceController.polygon.path
z: QGroundControl.zOrderMapItems
visible: geoFenceController.polygonSupported
}
// GeoFence circle
......@@ -797,6 +798,7 @@ QGCView {
center: missionController.plannedHomePosition
radius: geoFenceController.circleSupported ? geoFenceController.circleRadius : 0
z: QGroundControl.zOrderMapItems
visible: geoFenceController.circleSupported
}
// GeoFence breach return point
......
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