refactor(color): use LVGL styles and objects for UI, legacy cleanup (#4407)
This commit is contained in:
@@ -21,7 +21,6 @@
|
||||
|
||||
#include "opentx.h"
|
||||
#include "calibration.h"
|
||||
#include "gui.h"
|
||||
|
||||
#include "hal/adc_driver.h"
|
||||
|
||||
|
||||
@@ -220,6 +220,7 @@ void runPopupWarning(event_t event)
|
||||
|
||||
void showAlertBox(const char * title, const char * text, const char * action , uint8_t sound)
|
||||
{
|
||||
cancelSplash();
|
||||
drawAlertBox(title, text, action);
|
||||
AUDIO_ERROR_MESSAGE(sound);
|
||||
lcdRefresh();
|
||||
|
||||
@@ -61,13 +61,14 @@ void showAlertBox(const char * title, const char * text, const char * action , u
|
||||
void drawProgressScreen(const char * title, const char * message, int num, int den);
|
||||
typedef void (* ProgressHandler)(const char *, const char *, int, int);
|
||||
|
||||
enum
|
||||
enum WarningType
|
||||
{
|
||||
WARNING_TYPE_WAIT,
|
||||
WARNING_TYPE_INFO,
|
||||
WARNING_TYPE_ASTERISK,
|
||||
WARNING_TYPE_CONFIRM,
|
||||
WARNING_TYPE_INPUT
|
||||
WARNING_TYPE_INPUT,
|
||||
WARNING_TYPE_ALERT
|
||||
};
|
||||
|
||||
#if !defined(GUI)
|
||||
|
||||
@@ -22,8 +22,16 @@
|
||||
#include "opentx.h"
|
||||
#include "inactivity_timer.h"
|
||||
|
||||
static bool splashStarted = false;
|
||||
|
||||
void startSplash()
|
||||
{
|
||||
splashStarted = true;
|
||||
}
|
||||
|
||||
void cancelSplash()
|
||||
{
|
||||
splashStarted = false;
|
||||
}
|
||||
|
||||
void waitSplash()
|
||||
@@ -34,7 +42,7 @@ void waitSplash()
|
||||
bool refresh = false;
|
||||
#endif
|
||||
|
||||
if (SPLASH_NEEDED()) {
|
||||
if (SPLASH_NEEDED() && splashStarted) {
|
||||
resetBacklightTimeout();
|
||||
drawSplash();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user