From 23dfa6570eade7c9436180d5055629357c47d296 Mon Sep 17 00:00:00 2001 From: davidsastresas Date: Tue, 19 Mar 2024 02:54:56 +0100 Subject: [PATCH] Vehicle: add roiCoordChanged signal: this allows for ROI commanded elsewhere than clicking on map ( like gimbal panel point home action ) to show the ROI indicator on map --- src/Vehicle/Vehicle.cc | 2 ++ src/Vehicle/Vehicle.h | 1 + 2 files changed, 3 insertions(+) diff --git a/src/Vehicle/Vehicle.cc b/src/Vehicle/Vehicle.cc index d7a411c9880..5db98893f8c 100644 --- a/src/Vehicle/Vehicle.cc +++ b/src/Vehicle/Vehicle.cc @@ -2892,6 +2892,8 @@ void Vehicle::guidedModeROI(const QGeoCoordinate& centerCoord) static_cast(centerCoord.longitude()), static_cast(centerCoord.altitude())); } + // This is picked by qml to display coordinate over map + emit roiCoordChanged(centerCoord); } void Vehicle::stopGuidedModeROI() diff --git a/src/Vehicle/Vehicle.h b/src/Vehicle/Vehicle.h index 1034e0f96ad..eda6214a616 100644 --- a/src/Vehicle/Vehicle.h +++ b/src/Vehicle/Vehicle.h @@ -1021,6 +1021,7 @@ public slots: void mavlinkStatusChanged (); void isROIEnabledChanged (); + void roiCoordChanged (const QGeoCoordinate& centerCoord); void initialConnectComplete (); void sensorsParametersResetAck (bool success);