1
0
Fork 0
forked from len0rd/rockbox

Ignore ON button in ask_resume(), to avoid mistakenly cancelling resume.

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@3925 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Björn Stenberg 2003-08-06 17:30:40 +00:00
parent 143da86b02
commit 7f67717b00

View file

@ -549,6 +549,8 @@ static int showdir(char *path, int start)
static bool ask_resume(bool ask_once) static bool ask_resume(bool ask_once)
{ {
bool stop = false;
#ifdef HAVE_LCD_CHARCELLS #ifdef HAVE_LCD_CHARCELLS
lcd_double_height(false); lcd_double_height(false);
#endif #endif
@ -568,14 +570,27 @@ static bool ask_resume(bool ask_once)
#endif #endif
lcd_update(); lcd_update();
switch (button_get(true)) { while (!stop) {
case BUTTON_PLAY: switch (button_get(true)) {
case BUTTON_RC_PLAY: case BUTTON_PLAY:
return true; case BUTTON_RC_PLAY:
return true;
case SYS_USB_CONNECTED: /* ignore the ON button, since it might
usb_screen(); still be pressed since booting */
break; case BUTTON_ON:
case BUTTON_ON | BUTTON_REL:
break;
case SYS_USB_CONNECTED:
usb_screen();
stop = true;
break;
default:
stop = true;
break;
}
} }
if ( global_settings.resume == RESUME_ASK_ONCE && ask_once) { if ( global_settings.resume == RESUME_ASK_ONCE && ask_once) {