1
0
Fork 0
forked from len0rd/rockbox

H1x0: Fixed the non-working Stop in the file browser. Ondios: Added the same feature.

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7677 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Jens Arnold 2005-10-28 21:57:30 +00:00
parent c01b987cca
commit eb87ad5e32
2 changed files with 6 additions and 5 deletions

View file

@ -649,14 +649,14 @@ static bool dirbrowse(void)
break; break;
#ifdef TREE_OFF #ifdef TREE_OFF
#if (CONFIG_KEYPAD == RECORDER_PAD) && !defined(HAVE_SW_POWEROFF)
case TREE_OFF: case TREE_OFF:
if (*tc.dirfilter < NUM_FILTER_MODES) if (*tc.dirfilter < NUM_FILTER_MODES)
{ {
/* Stop the music if it is playing, else power off */ /* Stop the music if it is playing */
if(audio_status()) if(audio_status())
audio_stop(); audio_stop();
else { #if (CONFIG_KEYPAD == RECORDER_PAD) && !defined(HAVE_SW_POWEROFF)
else {
if (!charger_inserted()) { if (!charger_inserted()) {
if(shutdown_screen()) if(shutdown_screen())
reload_dir = true; reload_dir = true;
@ -665,9 +665,9 @@ static bool dirbrowse(void)
} }
restore = true; restore = true;
} }
#endif
} }
break; break;
#endif
#if defined(HAVE_CHARGING) && !defined(HAVE_POWEROFF_WHILE_CHARGING) #if defined(HAVE_CHARGING) && !defined(HAVE_POWEROFF_WHILE_CHARGING)
case TREE_OFF | BUTTON_REPEAT: case TREE_OFF | BUTTON_REPEAT:
if (charger_inserted()) { if (charger_inserted()) {
@ -676,7 +676,7 @@ static bool dirbrowse(void)
} }
break; break;
#endif #endif
#endif #endif /* TREE_OFF */
case TREE_MENU: case TREE_MENU:
#ifdef TREE_RC_MENU #ifdef TREE_RC_MENU
case TREE_RC_MENU: case TREE_RC_MENU:

View file

@ -107,6 +107,7 @@
#define TREE_RUN_PRE BUTTON_RIGHT #define TREE_RUN_PRE BUTTON_RIGHT
#define TREE_MENU (BUTTON_MENU | BUTTON_REPEAT) #define TREE_MENU (BUTTON_MENU | BUTTON_REPEAT)
#define TREE_MENU_PRE BUTTON_MENU #define TREE_MENU_PRE BUTTON_MENU
#define TREE_OFF BUTTON_OFF
#define TREE_WPS (BUTTON_MENU | BUTTON_REL) #define TREE_WPS (BUTTON_MENU | BUTTON_REL)
#define TREE_WPS_PRE BUTTON_MENU #define TREE_WPS_PRE BUTTON_MENU
#define TREE_CONTEXT (BUTTON_RIGHT | BUTTON_REPEAT) #define TREE_CONTEXT (BUTTON_RIGHT | BUTTON_REPEAT)