chore(color): cleanup UI code (#6989)
This commit is contained in:
@@ -19,9 +19,13 @@
|
||||
* GNU General Public License for more details.
|
||||
*/
|
||||
|
||||
#include "edgetx.h"
|
||||
#include "battery_driver.h"
|
||||
|
||||
#include "boards/generic_stm32/rgb_leds.h"
|
||||
#include "edgetx.h"
|
||||
#include "mainwindow.h"
|
||||
#include "static.h"
|
||||
#include "LvglWrapper.h"
|
||||
|
||||
#define __BATTERY_DRIVER_C__
|
||||
|
||||
@@ -403,6 +407,8 @@ void drawChargingInfo(uint16_t chargeState) {
|
||||
}
|
||||
|
||||
if (chargeWindow == nullptr) {
|
||||
// Ensure lvgl is initialised before creating windows
|
||||
LvglWrapper::instance();
|
||||
chargeWindow = new Window(MainWindow::instance(), {0, 0, LCD_W, LCD_H});
|
||||
etx_solid_bg(chargeWindow->getLvObj(), COLOR_THEME_PRIMARY1_INDEX);
|
||||
|
||||
|
||||
@@ -42,6 +42,7 @@
|
||||
#include "sdcard.h"
|
||||
#include "touch.h"
|
||||
#include "debug.h"
|
||||
#include "keys.h"
|
||||
|
||||
#if defined(AUDIO_SPI)
|
||||
#include "vs1053b.h"
|
||||
@@ -51,9 +52,6 @@
|
||||
#include "battery_driver.h"
|
||||
#include "touch_driver.h"
|
||||
|
||||
#include "bitmapbuffer.h"
|
||||
#include "colors.h"
|
||||
|
||||
#include <string.h>
|
||||
|
||||
// Common ADC driver
|
||||
|
||||
Reference in New Issue
Block a user