1
0
Fork 0
forked from len0rd/rockbox

Ignore prev/next up unless last button was down

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@2152 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Björn Stenberg 2002-09-03 11:25:45 +00:00
parent 34835ccd0e
commit a3ea73782f

View file

@ -552,10 +552,10 @@ static bool menu(void)
button_set_release(old_release_mask);
main_menu();
#ifdef HAVE_LCD_BITMAP
if(global_settings.statusbar)
lcd_setmargins(0, STATUSBAR_HEIGHT);
else
lcd_setmargins(0, 0);
if(global_settings.statusbar)
lcd_setmargins(0, STATUSBAR_HEIGHT);
else
lcd_setmargins(0, 0);
#endif
old_release_mask = button_set_release(RELEASE_MASK);
}
@ -632,7 +632,7 @@ static bool menu(void)
/* demonstrates showing different formats from playtune */
int wps_show(void)
{
int button;
int button, lastbutton = 0;
bool ignore_keyup = true;
bool restore = false;
@ -743,6 +743,9 @@ int wps_show(void)
/* prev / restart */
case BUTTON_LEFT | BUTTON_REL:
if ( lastbutton != BUTTON_LEFT )
break;
if (!id3 || (id3->elapsed < 3*1000))
mpeg_prev();
else {
@ -758,6 +761,8 @@ int wps_show(void)
/* next */
case BUTTON_RIGHT | BUTTON_REL:
if ( lastbutton != BUTTON_RIGHT )
break;
mpeg_next();
break;
@ -820,5 +825,6 @@ int wps_show(void)
if (id3)
wps_refresh(id3,0,false);
}
lastbutton = button;
}
}