menu+left/right was broken for volume change. Patch submitted by

Magnus Holmgren.


git-svn-id: svn://svn.rockbox.org/rockbox/trunk@1772 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Mats Lidell 2002-08-16 05:16:51 +00:00
parent 0edcd0a7bf
commit a5cc9c93cf

View file

@ -569,6 +569,8 @@ int wps_show(void)
break;
case BUTTON_LEFT | BUTTON_REL:
if (!keys_locked)
{
if (ff_rewind)
{
/* rewind */
@ -580,20 +582,30 @@ int wps_show(void)
draw_screen(id3);
#endif
}
#ifdef HAVE_PLAYER_KEYPAD
else if(!menu_button_is_down)
#else
else
#endif
{
if (keys_locked)
mpeg_prev();
status_set_playmode(STATUS_PLAY);
}
}
#ifdef HAVE_PLAYER_KEYPAD
else if(!menu_button_is_down)
#else
else
#endif
{
display_keylock_text(keys_locked);
draw_screen(id3);
break;
}
mpeg_prev();
status_set_playmode(STATUS_PLAY);
}
break;
case BUTTON_RIGHT | BUTTON_REL:
if (!keys_locked)
{
if (ff_rewind)
{
/* fast forward */
@ -605,17 +617,26 @@ int wps_show(void)
draw_screen(id3);
#endif
}
#ifdef HAVE_PLAYER_KEYPAD
else if(!menu_button_is_down)
#else
else
#endif
{
if (keys_locked)
mpeg_next();
status_set_playmode(STATUS_PLAY);
}
}
#ifdef HAVE_PLAYER_KEYPAD
else if(!menu_button_is_down)
#else
else
#endif
{
display_keylock_text(keys_locked);
draw_screen(id3);
break;
}
mpeg_next();
status_set_playmode(STATUS_PLAY);
}
break;
#ifdef HAVE_PLAYER_KEYPAD
@ -626,6 +647,7 @@ int wps_show(void)
if(global_settings.volume < mpeg_sound_min(SOUND_VOLUME))
global_settings.volume = mpeg_sound_min(SOUND_VOLUME);
mpeg_sound_set(SOUND_VOLUME, global_settings.volume);
status_draw();
settings_save();
break;
@ -636,6 +658,7 @@ int wps_show(void)
if(global_settings.volume > mpeg_sound_max(SOUND_VOLUME))
global_settings.volume = mpeg_sound_max(SOUND_VOLUME);
mpeg_sound_set(SOUND_VOLUME, global_settings.volume);
status_draw();
settings_save();
break;