feat: Add options to disable radio and model menu tabs (#3484)
* Add options to disable radio and model menu tabs. - Update radio and model data structs - UI for color LCD radios - Convert existing 'noGlobalFunctions' property. - Language strings. * Make 'theme' control specific to color LCD radios. * Add B&W radio UI. * Simplify code, reduce compiled code size. Fix page count display on model select tab. Fix GVARS for 212x64 radios. * Collapse timer sections if timer is off. * Remove 'Use global functions' checkbox from B&W model setup. * Make preflight checks, throttle and view options sections expand & collapse (default collapsed). * Fix build. * Add view options to companion data classes, save and load values in YAML files. Fix scrolling for radio setup view options. * Add Companion UI for view option settings. * Remove 'Mixes' from list of tabs that can be hidden. * Updated Companion UI from elecpower. * Use view options flags to enable/disable functionality: - skip heli mixer logic if heli not enabled - Remove heli, gvars and telemetry options from source selection if not enabled * Remove 'flight mode', 'curve' and 'global variable' settings from input & mix editors if option disabled. * Rename 'View Options' to 'Enabled Features'. Put GVAR option under Flight Mode and indent text. Make relationship between FM and GV more obvious. * Remove global variable option dependency on flight modes. Hide FM1-FM8 in global variables if flight modes hidden. * Hide 'Custom Mixer Scripts' in source selection menu popup if disabled. * Add translation strings for Hebrew language file. * Fix typo. Add comment for double call to setCurrentTab.
This commit is contained in:
@@ -208,7 +208,7 @@ void menuModelSelect(event_t event)
|
||||
|
||||
case EVT_KEY_BREAK(KEY_PAGE):
|
||||
case EVT_KEY_LONG(KEY_PAGE):
|
||||
chainMenu(event == EVT_KEY_BREAK(KEY_PAGE) ? menuModelSetup : menuTabModel[DIM(menuTabModel)-1]);
|
||||
chainMenu(event == EVT_KEY_BREAK(KEY_PAGE) ? menuModelSetup : menuTabModel[DIM(menuTabModel)-1].menuFunc);
|
||||
killEvents(event);
|
||||
break;
|
||||
|
||||
@@ -249,7 +249,8 @@ void menuModelSelect(event_t event)
|
||||
lcdDrawText(lcdLastRightPos + 3, 0, STR_FREE);
|
||||
#endif
|
||||
|
||||
drawScreenIndex(MENU_MODEL_SELECT, DIM(menuTabModel), 0);
|
||||
extern uint8_t menuSize(const MenuHandler*, uint8_t);
|
||||
drawScreenIndex(MENU_MODEL_SELECT, menuSize(menuTabModel, DIM(menuTabModel)), 0);
|
||||
lcdDrawFilledRect(0, 0, LCD_W, FH, SOLID, FILL_WHITE|GREY_DEFAULT);
|
||||
|
||||
title(STR_MENUMODELSEL);
|
||||
|
||||
Reference in New Issue
Block a user