Commit c53977fb authored by Tomaz Canabrava's avatar Tomaz Canabrava Committed by Daniel Agar

MultiVehicleManager: use qobject_cast instead of dynamic_cast

qobject_cast is times faster dynamic_cast for objects that
inherit QObject. also, use auto keyword to not duplicate
class names.
parent ae8f94a7
......@@ -304,7 +304,7 @@ void MultiVehicleManager::_setActiveVehiclePhase2(void)
void MultiVehicleManager::_vehicleParametersReadyChanged(bool parametersReady)
ParameterManager* paramMgr = dynamic_cast<ParameterManager*>(sender());
auto* paramMgr = qobject_cast<ParameterManager*>(sender());
if (!paramMgr) {
qWarning() << "Dynamic cast failed!";
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