From 4b14deeebc7aa17e5f0ff526d0fc97c6ece157f8 Mon Sep 17 00:00:00 2001 From: Darren Lines Date: Mon, 2 Nov 2020 20:06:42 +0000 Subject: [PATCH] Update auxiliary.js Added checks for modes not in the configuratorBoxOrder array. --- tabs/auxiliary.js | 40 ++++++++++++++++++++++++++++++---------- 1 file changed, 30 insertions(+), 10 deletions(-) diff --git a/tabs/auxiliary.js b/tabs/auxiliary.js index b6a1e6f6..2cfaaeb9 100644 --- a/tabs/auxiliary.js +++ b/tabs/auxiliary.js @@ -33,7 +33,7 @@ TABS.auxiliary.initialize = function (callback) { } function sort_modes_for_display() { - // This array defines the order that the modes are displayed in the configurator modes page. + // This array defines the order that the modes are displayed in the configurator modes page configuratorBoxOrder = [ "ARM", // Arming "ANGLE", "HORIZON", "MANUAL", // Flight modes @@ -49,26 +49,46 @@ TABS.auxiliary.initialize = function (callback) { ]; // Sort the modes - tmpAUX_CONFIG =[]; - tmpAUX_CONFIG_IDS = []; - for (i=0;i AUX_CONFIG.length) { + for (i=0; i