Commit 326b6e85 authored by Tomaz Canabrava's avatar Tomaz Canabrava Committed by Daniel Agar

Map to bracket initializer

parent 63719ff2
...@@ -32,18 +32,17 @@ FirmwarePlugin::remapParamNameMajorVersionMap_t ArduSubFirmwarePlugin::_remapPar ...@@ -32,18 +32,17 @@ FirmwarePlugin::remapParamNameMajorVersionMap_t ArduSubFirmwarePlugin::_remapPar
APMSubMode::APMSubMode(uint32_t mode, bool settable) : APMSubMode::APMSubMode(uint32_t mode, bool settable) :
APMCustomMode(mode, settable) APMCustomMode(mode, settable)
{ {
QMap<uint32_t,QString> enumToString; setEnumToStringMapping({
enumToString.insert(MANUAL, "Manual"); {MANUAL, "Manual"},
enumToString.insert(STABILIZE, "Stabilize"); {STABILIZE, "Stabilize"},
enumToString.insert(ACRO, "Acro"); {ACRO, "Acro"},
enumToString.insert(ALT_HOLD, "Depth Hold"); {ALT_HOLD, "Depth Hold"},
enumToString.insert(AUTO, "Auto"); {AUTO, "Auto"},
enumToString.insert(GUIDED, "Guided"); {GUIDED, "Guided"},
enumToString.insert(CIRCLE, "Circle"); {CIRCLE, "Circle"},
enumToString.insert(SURFACE, "Surface"); {SURFACE, "Surface"},
enumToString.insert(POSHOLD, "Position Hold"); {POSHOLD, "Position Hold"},
});
setEnumToStringMapping(enumToString);
} }
ArduSubFirmwarePlugin::ArduSubFirmwarePlugin(void): ArduSubFirmwarePlugin::ArduSubFirmwarePlugin(void):
......
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