Commit a110c38d authored by DonLakeFlyer's avatar DonLakeFlyer

Remove duplicated flight mode talking

parent cbb898fb
......@@ -989,9 +989,12 @@ void Vehicle::_handleHeartbeat(mavlink_message_t& message)
}
if (heartbeat.base_mode != _base_mode || heartbeat.custom_mode != _custom_mode) {
QString previousFlightMode = flightMode();
_base_mode = heartbeat.base_mode;
_custom_mode = heartbeat.custom_mode;
emit flightModeChanged(flightMode());
if (previousFlightMode != flightMode()) {
emit flightModeChanged(flightMode());
}
}
}
......
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