Strings can be expensive to create, all the issues with allocation,
copy of the char members, conversion to UTF-16. QStringLiteral creates
one in compile time.
Signed-off-by: Tomaz Canabrava <tomaz.canabrava@intel.com>
There are many ways of iterating over lists in C++/Qt.
In the specific case of QStrings, it is known [1] that using
foreach with const references avoids the creation of new
QString objects in each iteration, reducing the time consumed
by the loops.
[1] https://blog.qt.io/blog/2009/01/23/iterating-efficiently/
Signed-off-by: Anselmo L. S. Melo <anselmo.melo@intel.com>
This commit introduces the APM Airframe configuration. The interface
is the same as the PX4 one, but the way we deal with the uas is a bit different
Since the APM stack doesn't provide a xml with airframe definitions a
new one was created by hand with only the values that we need, wich will
trigger a download of the parameters file from the mavlink github
Now it correctly handles the FRAME variable and it's faster
regarding the download of the parameters for each type of Frame.
Only show Airframes for ArduCopter, not for ArduRover nor ArduPlane
Signed-off-by: Tomaz Canabrava <tomaz.canabrava@intel.com>