summaryrefslogtreecommitdiffstats
path: root/apps/menu.c
diff options
context:
space:
mode:
authorThomas Martitz <kugel@rockbox.org>2010-10-31 15:32:57 +0000
committerThomas Martitz <kugel@rockbox.org>2010-10-31 15:32:57 +0000
commit49f1ec8e8ad0b4c06df01fcdd4b18037fbe3ebcc (patch)
treeb185e604dcea64865389f5b149e754ba8ffd3f75 /apps/menu.c
parentdbe2ac1ec6f4ed88f267d2a4df024b6dc42a87ff (diff)
downloadrockbox-49f1ec8e8ad0b4c06df01fcdd4b18037fbe3ebcc.tar.gz
rockbox-49f1ec8e8ad0b4c06df01fcdd4b18037fbe3ebcc.tar.bz2
rockbox-49f1ec8e8ad0b4c06df01fcdd4b18037fbe3ebcc.zip
Add support multimedia keys/buttons to the core, and adapt Rockbox on android for it (multimedia buttons are found on wired headsets and the lock screen in cyanogenmod).
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28421 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/menu.c')
-rw-r--r--apps/menu.c16
1 files changed, 13 insertions, 3 deletions
diff --git a/apps/menu.c b/apps/menu.c
index 9d67c7b03e..5839a51c21 100644
--- a/apps/menu.c
+++ b/apps/menu.c
@@ -650,10 +650,20 @@ int do_menu(const struct menu_item_ex *start_menu, int *start_selected,
}
#endif
}
- else if(default_event_handler(action) == SYS_USB_CONNECTED)
+ else
{
- ret = MENU_ATTACHED_USB;
- done = true;
+ switch(default_event_handler(action))
+ {
+ case SYS_USB_CONNECTED:
+ ret = MENU_ATTACHED_USB;
+ done = true;
+ break;
+ case SYS_CALL_HUNG_UP:
+ case BUTTON_MULTIMEDIA_PLAYPAUSE:
+ /* remove splash from playlist_resume() */
+ redraw_lists = true;
+ break;
+ }
}
if (redraw_lists && !done)