summaryrefslogtreecommitdiffstats
path: root/firmware
diff options
context:
space:
mode:
authorMichael Sevakis <jethead71@rockbox.org>2009-01-23 22:45:33 +0000
committerMichael Sevakis <jethead71@rockbox.org>2009-01-23 22:45:33 +0000
commitef8413eb4fd7fead45d33b3ecae003210978b85d (patch)
treeaef037e05b55c3c1600b08222a67962341158788 /firmware
parentf8816724112cf035fc18889235ce84a76bb34803 (diff)
downloadrockbox-ef8413eb4fd7fead45d33b3ecae003210978b85d.tar.gz
rockbox-ef8413eb4fd7fead45d33b3ecae003210978b85d.zip
Gigabeat S: Make sure the hold button on the remote is independent of the main one.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19833 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware')
-rw-r--r--firmware/target/arm/imx31/gigabeat-s/button-imx31.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/firmware/target/arm/imx31/gigabeat-s/button-imx31.c b/firmware/target/arm/imx31/gigabeat-s/button-imx31.c
index dec0aa108f..9c35fb13da 100644
--- a/firmware/target/arm/imx31/gigabeat-s/button-imx31.c
+++ b/firmware/target/arm/imx31/gigabeat-s/button-imx31.c
@@ -150,8 +150,14 @@ int button_read_device(void)
* first key down event. */
KPP_KPSR |= KPP_KPSR_KDIE;
- /* If hold, ignore any pressed button */
+#ifdef HAVE_HEADPHONE_DETECTION
+ /* If hold, ignore any pressed button. Remote has its own hold
+ * switch, so return state regardless. */
+ return hold_button ? (int_btn & BUTTON_REMOTE) : int_btn;
+#else
+ /* If hold, ignore any pressed button. */
return hold_button ? BUTTON_NONE : int_btn;
+#endif
}
/* This is called from the mc13783 interrupt thread */