mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-11-18 01:22:38 -05:00
New feature: clean shutdown if you press OFF twice in the file browser, or select "Shut
off" in the main menu. Players only have the menu option, due to lack of keys. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@4940 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
6b8d020876
commit
5b5003dcb1
9 changed files with 113 additions and 13 deletions
|
|
@ -60,6 +60,7 @@ long mp3_get_playtime(void);
|
|||
void mp3_reset_playtime(void);
|
||||
bool mp3_is_playing(void);
|
||||
unsigned char* mp3_get_pos(void);
|
||||
void mp3_shutdown(void);
|
||||
|
||||
|
||||
#define SOUND_VOLUME 0
|
||||
|
|
|
|||
|
|
@ -1028,6 +1028,20 @@ void mp3_init(int volume, int bass, int treble, int balance, int loudness,
|
|||
paused = true;
|
||||
}
|
||||
|
||||
void mp3_shutdown(void)
|
||||
{
|
||||
#ifndef SIMULATOR
|
||||
#ifdef HAVE_MAS3587F
|
||||
unsigned long val = 1;
|
||||
mas_writemem(MAS_BANK_D0, 0x7f9, &val, 1); /* Mute */
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_MAS3507D
|
||||
dac_volume(0, 0, false);
|
||||
#endif
|
||||
|
||||
#endif
|
||||
}
|
||||
|
||||
/* new functions, to be exported to plugin API */
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue