summaryrefslogtreecommitdiffstats
path: root/firmware/target/arm/rk27xx/hm801/button-hm801.c
diff options
context:
space:
mode:
Diffstat (limited to 'firmware/target/arm/rk27xx/hm801/button-hm801.c')
-rw-r--r--firmware/target/arm/rk27xx/hm801/button-hm801.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/firmware/target/arm/rk27xx/hm801/button-hm801.c b/firmware/target/arm/rk27xx/hm801/button-hm801.c
index 0ac1b3b0aa..5f01a7bd14 100644
--- a/firmware/target/arm/rk27xx/hm801/button-hm801.c
+++ b/firmware/target/arm/rk27xx/hm801/button-hm801.c
@@ -137,9 +137,11 @@ static int button_read_device_v2(void) {
int button_read_device(void) {
static bool hold_button = false;
+#ifndef BOOTLOADER
bool hold_button_old;
hold_button_old = hold_button;
+#endif
hold_button = button_hold();
#ifndef BOOTLOADER
@@ -147,7 +149,7 @@ int button_read_device(void) {
backlight_hold_changed(hold_button);
}
#endif
-
+
if (hold_button) {
return 0;
} else if (kbd_type == KEYBOARD_V1) {