Merge against latest 2.3

This commit is contained in:
Bertrand Songis
2019-09-17 13:28:42 +02:00
247 changed files with 35085 additions and 42445 deletions
+18 -8
View File
@@ -81,6 +81,9 @@ enum
inline void CLEAR_POPUP()
{
warningText = nullptr;
warningInfoText = nullptr;
popupMenuHandler = nullptr;
popupMenuItemsCount = 0;
}
inline void POPUP_WAIT(const char * s)
@@ -109,11 +112,14 @@ enum
inline void POPUP_CONFIRMATION(const char * s, PopupMenuHandler handler)
{
warningText = s;
warningInfoText = nullptr;
warningType = WARNING_TYPE_CONFIRM;
popupFunc = runPopupWarning;
popupMenuHandler = handler;
if (s != warningText) {
killAllEvents();
warningText = s;
warningInfoText = nullptr;
warningType = WARNING_TYPE_CONFIRM;
popupFunc = runPopupWarning;
popupMenuHandler = handler;
}
}
inline void POPUP_INPUT(const char * s, PopupFunc func)
@@ -146,8 +152,9 @@ enum
inline void POPUP_MENU_ADD_ITEM(const char * s)
{
popupMenuOffsetType = MENU_OFFSET_INTERNAL;
if (popupMenuItemsCount < POPUP_MENU_MAX_LINES)
if (popupMenuItemsCount < POPUP_MENU_MAX_LINES) {
popupMenuItems[popupMenuItemsCount++] = s;
}
}
#if defined(SDCARD)
@@ -163,8 +170,11 @@ inline void POPUP_MENU_SELECT_ITEM(uint8_t index)
inline void POPUP_MENU_START(PopupMenuHandler handler)
{
popupMenuHandler = handler;
AUDIO_KEY_PRESS();
if (handler != popupMenuHandler) {
killAllEvents();
AUDIO_KEY_PRESS();
popupMenuHandler = handler;
}
}
#endif // _STDLCD_POPUPS_H_