Remove old AVR stuff + cosmetics
This commit is contained in:
@@ -268,13 +268,14 @@ void menuModelLogicalSwitches(event_t event)
|
||||
POPUP_MENU_ADD_ITEM(STR_PASTE);
|
||||
if (cs->func || cs->v1 || cs->v2 || cs->delay || cs->duration || cs->andsw)
|
||||
POPUP_MENU_ADD_ITEM(STR_CLEAR);
|
||||
if(popupMenuItemsCount == 1) {
|
||||
if (popupMenuItemsCount == 1) {
|
||||
popupMenuItemsCount = 0;
|
||||
s_currIdx = sub;
|
||||
pushMenu(menuModelLogicalSwitchOne);
|
||||
}
|
||||
else
|
||||
else {
|
||||
POPUP_MENU_START(onLogicalSwitchesMenu);
|
||||
}
|
||||
}
|
||||
|
||||
for (uint8_t i=0; i<LCD_LINES-1; i++) {
|
||||
|
||||
@@ -47,7 +47,6 @@ void onModelSelectMenu(const char * result)
|
||||
else if (result == STR_RESTORE_MODEL || result == STR_UPDATE_LIST) {
|
||||
if (!sdListFiles(MODELS_PATH, MODELS_EXT, MENU_LINE_LENGTH-1, NULL)) {
|
||||
POPUP_WARNING(STR_NO_MODELS_ON_SD);
|
||||
POPUP_MENU_UNSET_BSS_FLAG();
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -59,7 +59,6 @@ void onCustomFunctionsFileSelectionMenu(const char * result)
|
||||
}
|
||||
if (!sdListFiles(directory, func==FUNC_PLAY_SCRIPT ? SCRIPTS_EXT : SOUNDS_EXT, sizeof(cfn->play.name), nullptr)) {
|
||||
POPUP_WARNING(func==FUNC_PLAY_SCRIPT ? STR_NO_SCRIPTS_ON_SD : STR_NO_SOUNDS_ON_SD);
|
||||
POPUP_MENU_UNSET_BSS_FLAG();
|
||||
}
|
||||
}
|
||||
else if (result != STR_EXIT) {
|
||||
@@ -317,7 +316,6 @@ void menuSpecialFunctions(event_t event, CustomFunctionData * functions, CustomF
|
||||
}
|
||||
else {
|
||||
POPUP_WARNING(func==FUNC_PLAY_SCRIPT ? STR_NO_SCRIPTS_ON_SD : STR_NO_SOUNDS_ON_SD);
|
||||
POPUP_MENU_UNSET_BSS_FLAG();
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -502,7 +502,7 @@ extern uint8_t warningInfoFlags;
|
||||
#define POPUP_MENU_MAX_LINES 12
|
||||
#define MENU_MAX_DISPLAY_LINES 9
|
||||
#define MENU_LINE_LENGTH (LEN_MODEL_NAME+12)
|
||||
#define POPUP_MENU_SET_BSS_FLAG()
|
||||
|
||||
extern const char * popupMenuItems[POPUP_MENU_MAX_LINES];
|
||||
extern uint16_t popupMenuItemsCount;
|
||||
extern uint16_t popupMenuOffset;
|
||||
|
||||
@@ -62,7 +62,6 @@ bool menuRadioTools(event_t event)
|
||||
|
||||
MENU(STR_MENUTOOLS, RADIO_ICONS, menuTabGeneral, MENU_RADIO_TOOLS, spectrum_modules + power_modules, {0,0,0,0});
|
||||
|
||||
|
||||
uint8_t menu_index = 0;
|
||||
|
||||
if (isModuleOptionAvailable(reusableBuffer.hardwareAndSettings.modules[INTERNAL_MODULE].information.modelID, MODULE_OPTION_SPECTRUM_ANALYSER))
|
||||
|
||||
+4
-1
@@ -310,7 +310,9 @@ void guiMain(event_t evt)
|
||||
}
|
||||
if (popupDisplayed == false || evt) {
|
||||
popupDisplayed = lcdRestoreBackupBuffer();
|
||||
if (warn) DISPLAY_WARNING(evt);
|
||||
if (warn) {
|
||||
DISPLAY_WARNING(evt);
|
||||
}
|
||||
if (menu) {
|
||||
const char * result = runPopupMenu(evt);
|
||||
if (popupMenuItemsCount == 0) {
|
||||
@@ -462,6 +464,7 @@ void guiMain(event_t evt)
|
||||
void perMain()
|
||||
{
|
||||
DEBUG_TIMER_START(debugTimerPerMain1);
|
||||
|
||||
#if defined(PCBSKY9X) && !defined(REVA)
|
||||
calcConsumption();
|
||||
#endif
|
||||
|
||||
@@ -303,7 +303,6 @@ bool sdListFiles(const char * path, const char * extension, const uint8_t maxlen
|
||||
}
|
||||
|
||||
popupMenuItemsCount = 0;
|
||||
POPUP_MENU_SET_BSS_FLAG();
|
||||
|
||||
FRESULT res = f_opendir(&dir, path);
|
||||
if (res == FR_OK) {
|
||||
|
||||
Reference in New Issue
Block a user