summaryrefslogtreecommitdiffstats
path: root/firmware/target/arm/rk27xx/hm60x/button-hm60x.c
diff options
context:
space:
mode:
authorSolomon Peachy <pizza@shaftnet.org>2020-10-13 19:32:07 -0400
committerSolomon Peachy <pizza@shaftnet.org>2020-10-13 19:45:03 -0400
commit26bebd77abe94abd415ff46d67b52153dd19f85b (patch)
tree59922d7da82611fd2951051a0e7869a325d2bff1 /firmware/target/arm/rk27xx/hm60x/button-hm60x.c
parente2adc6781fded00884ddb0161eb0f53b967f4785 (diff)
downloadrockbox-26bebd77ab.tar.gz
rockbox-26bebd77ab.tar.bz2
rockbox-26bebd77ab.zip
Fix more red.
Change-Id: Id1a45b420f8eb70a25010b058822b78f80db33d8
Diffstat (limited to 'firmware/target/arm/rk27xx/hm60x/button-hm60x.c')
-rw-r--r--firmware/target/arm/rk27xx/hm60x/button-hm60x.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/firmware/target/arm/rk27xx/hm60x/button-hm60x.c b/firmware/target/arm/rk27xx/hm60x/button-hm60x.c
index dfd209ceed..fd5b6d6d20 100644
--- a/firmware/target/arm/rk27xx/hm60x/button-hm60x.c
+++ b/firmware/target/arm/rk27xx/hm60x/button-hm60x.c
@@ -43,11 +43,13 @@ int button_read_device(void) {
int adc_val = adc_read(ADC_BUTTONS);
int gpio_btn = GPIO_PCDR & BUTTON_POWER;
static bool hold_button = false;
+#ifndef BOOTLOADER
bool hold_button_old;
-
+
hold_button_old = hold_button;
+#endif
hold_button = button_hold();
-
+
#ifndef BOOTLOADER
if (hold_button != hold_button_old) {
backlight_hold_changed(hold_button);