[Horus] The backlight becomes ON when the PWR button is pressed

This commit is contained in:
Bertrand Songis
2016-06-04 09:30:37 +02:00
parent 348526b5ba
commit 068fa45a06
+6 -1
View File
@@ -954,8 +954,9 @@ void checkBacklight()
tmr10ms = x;
if (inputsMoved()) {
inactivity.counter = 0;
if (g_eeGeneral.backlightMode & e_backlight_mode_sticks)
if (g_eeGeneral.backlightMode & e_backlight_mode_sticks) {
backlightOn();
}
}
bool backlightOn = (g_eeGeneral.backlightMode == e_backlight_mode_on || lightOffCounter || isFunctionActive(FUNCTION_BACKLIGHT));
@@ -2735,6 +2736,10 @@ uint32_t pwrCheck()
pwr_press_time = get_tmr10ms();
}
else {
inactivity.counter = 0;
if (g_eeGeneral.backlightMode != e_backlight_mode_off) {
BACKLIGHT_ON();
}
if (get_tmr10ms() - pwr_press_time > PWR_PRESS_SHUTDOWN) {
#if defined(SHUTDOWN_CONFIRMATION)
while (1) {