Fix songs_play_file use for sdlmixer=0
This commit is contained in:
parent
8376504a34
commit
c60c0352f0
|
@ -36,6 +36,13 @@ struct bim_song_info
|
|||
#define SONG_EXT_MP3 "mp3"
|
||||
#endif
|
||||
|
||||
#if !DXX_USE_SDLMIXER
|
||||
#ifdef _WIN32
|
||||
#define songs_play_file(filename,repeat,hook_finished_track) songs_play_file(filename,repeat)
|
||||
#else
|
||||
#define songs_play_file(filename,repeat,hook_finished_track) songs_play_file()
|
||||
#endif
|
||||
#endif
|
||||
int songs_play_file(const char *filename, int repeat, void (*hook_finished_track)());
|
||||
#ifdef dsx
|
||||
namespace dsx {
|
||||
|
|
|
@ -325,7 +325,7 @@ static void play_credits_track()
|
|||
int songs_play_file(const char *filename, int repeat, void (*hook_finished_track)())
|
||||
{
|
||||
songs_stop_all();
|
||||
|
||||
#if defined(_WIN32) || DXX_USE_SDLMIXER
|
||||
const char *fptr = strrchr(filename, '.');
|
||||
if (fptr == NULL)
|
||||
return 0;
|
||||
|
@ -349,6 +349,7 @@ int songs_play_file(const char *filename, int repeat, void (*hook_finished_track
|
|||
{
|
||||
return mix_play_file( filename, repeat, hook_finished_track );
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue