Commit 5832b6a3 authored by Don Gagne's avatar Don Gagne

Don't show vehicle till 2d gps lock

parent 942b6d66
......@@ -166,8 +166,7 @@ Item {
delegate:
VehicleMapItem {
coordinate: object.coordinate
heading: object.heading
vehicle: object
isSatellite: root.isSatelliteMap
}
}
......@@ -236,6 +235,25 @@ Item {
*/
}
// Vehicle GPS lock display
Column {
id: gpsLockColumn
y: (parent.height - height) / 2
width: parent.width
Repeater {
model: multiVehicleManager.vehicles
delegate:
QGCLabel {
width: gpsLockColumn.width
horizontalAlignment: Text.AlignHCenter
visible: object.satelliteLock < 2
text: "No GPS Lock for Vehicle #" + object.id
}
}
}
// Mission item list
ListView {
id: missionItemSummaryList
......
......@@ -28,14 +28,17 @@ import QtQuick 2.4
import QtLocation 5.3
import QGroundControl.ScreenTools 1.0
import QGroundControl.Vehicle 1.0
/// Marker for displaying a vehicle location on the map
MapQuickItem {
property real heading: 0
property bool isSatellite: false
property var vehicle ///< Vehicle object
property bool isSatellite: false ///< true: satellite map is showing
anchorPoint.x: vehicleIcon.width / 2
anchorPoint.y: vehicleIcon.height / 2
coordinate: vehicle.coordinate
visible: vehicle.satelliteLock >= 2 // 2D lock
sourceItem: Image {
id: vehicleIcon
......@@ -47,7 +50,7 @@ MapQuickItem {
transform: Rotation {
origin.x: vehicleIcon.width / 2
origin.y: vehicleIcon.height / 2
angle: heading
angle: vehicle.heading
}
}
}
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