From 521201d297479f4378d83d517507e8c16901e513 Mon Sep 17 00:00:00 2001 From: Gus Grubba Date: Thu, 24 Oct 2019 16:44:20 -0400 Subject: [PATCH] Fix test for rally and geofence support. --- src/MissionManager/GeoFenceController.cc | 2 ++ src/MissionManager/RallyPointController.cc | 2 ++ 2 files changed, 4 insertions(+) diff --git a/src/MissionManager/GeoFenceController.cc b/src/MissionManager/GeoFenceController.cc index e9acf66..689349c 100644 --- a/src/MissionManager/GeoFenceController.cc +++ b/src/MissionManager/GeoFenceController.cc @@ -117,7 +117,9 @@ void GeoFenceController::managerVehicleChanged(Vehicle* managerVehicle) connect(_geoFenceManager, &GeoFenceManager::removeAllComplete, this, &GeoFenceController::_managerRemoveAllComplete); connect(_geoFenceManager, &GeoFenceManager::inProgressChanged, this, &GeoFenceController::syncInProgressChanged); + //-- GeoFenceController::supported() tests both the capability bit AND the protocol version. connect(_managerVehicle, &Vehicle::capabilityBitsChanged, this, &GeoFenceController::supportedChanged); + connect(_managerVehicle, &Vehicle::requestProtocolVersion, this, &GeoFenceController::supportedChanged); connect(_managerVehicle->parameterManager(), &ParameterManager::parametersReadyChanged, this, &GeoFenceController::_parametersReady); _parametersReady(); diff --git a/src/MissionManager/RallyPointController.cc b/src/MissionManager/RallyPointController.cc index e6f150f..60e9de4 100644 --- a/src/MissionManager/RallyPointController.cc +++ b/src/MissionManager/RallyPointController.cc @@ -71,7 +71,9 @@ void RallyPointController::managerVehicleChanged(Vehicle* managerVehicle) connect(_rallyPointManager, &RallyPointManager::removeAllComplete, this, &RallyPointController::_managerRemoveAllComplete); connect(_rallyPointManager, &RallyPointManager::inProgressChanged, this, &RallyPointController::syncInProgressChanged); + //-- RallyPointController::supported() tests both the capability bit AND the protocol version. connect(_managerVehicle, &Vehicle::capabilityBitsChanged, this, &RallyPointController::supportedChanged); + connect(_managerVehicle, &Vehicle::requestProtocolVersion, this, &RallyPointController::supportedChanged); emit supportedChanged(supported()); }