Commit 6a757481 authored by Don Gagne's avatar Don Gagne

Merge pull request #2625 from DonLakeFlyer/MapPosition

Initial map position incorrect
parents d2ad57c9 6960c436
......@@ -45,7 +45,7 @@ FlightMap {
property var activeVehicleCoordinate: multiVehicleManager.activeVehicle ? multiVehicleManager.activeVehicle.coordinate : QtPositioning.coordinate()
onActiveVehicleCoordinateChanged: {
if (_followVehicle && activeVehicleCoordinate.isValid) {
if (_followVehicle && _activeVehicleCoordinateValid && activeVehicleCoordinate.isValid) {
_initialMapPositionSet = true
flightMap.center = activeVehicleCoordinate
}
......
......@@ -85,7 +85,7 @@ QGCView {
}
function updateMapToVehiclePosition() {
if (_activeVehicle && _activeVehicle.coordinateValid && _firstVehiclePosition) {
if (_activeVehicle && _activeVehicle.coordinateValid && _activeVehicle.coordinate.isValid && _firstVehiclePosition) {
_firstVehiclePosition = false
editorMap.center = _activeVehicle.coordinate
}
......
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