Make rarch_playlist_push more useful

This commit is contained in:
twinaphex 2014-10-11 16:46:59 +02:00
parent 925d873d91
commit 65bc796011
4 changed files with 13 additions and 8 deletions

View File

@ -233,7 +233,10 @@ returntype main_entry(signature())
#if defined(RARCH_CONSOLE) || defined(RARCH_MOBILE)
if (ret)
#endif
rarch_playlist_push(g_defaults.history, g_extern.fullpath);
rarch_playlist_push(g_defaults.history,
g_extern.fullpath,
g_settings.libretro,
&g_extern.system.info);
#endif
#if defined(HAVE_MAIN_LOOP)

View File

@ -91,10 +91,10 @@ bool load_menu_content(void)
msg_queue_push(g_extern.msg_queue, str, 1, 1);
}
content_playlist_push(g_defaults.history,
rarch_playlist_push(g_defaults.history,
g_extern.fullpath,
g_settings.libretro,
g_extern.menu.info.library_name);
&g_extern.menu.info);
}
/* redraw menu frame */

View File

@ -18,11 +18,12 @@
#include "general.h"
void rarch_playlist_push(content_playlist_t *playlist,
const char *path)
const char *path, const char *core_path,
struct retro_system_info *info)
{
char tmp[PATH_MAX];
if (!playlist || !g_extern.libretro_dummy)
if (!playlist || !g_extern.libretro_dummy || !info)
return;
/* path can be relative here.
@ -36,8 +37,8 @@ void rarch_playlist_push(content_playlist_t *playlist,
if (g_extern.system.no_content || *tmp)
content_playlist_push(playlist,
*tmp ? tmp : NULL,
g_settings.libretro,
g_extern.system.info.library_name);
core_path,
info->library_name);
}
void rarch_playlist_load_content(content_playlist_t *playlist,

View File

@ -828,7 +828,8 @@ void rarch_disk_control_set_index(unsigned index);
void rarch_disk_control_append_image(const char *path);
void rarch_playlist_push(content_playlist_t *playlist,
const char *path);
const char *path, const char *core_path,
struct retro_system_info *info);
void rarch_playlist_load_content(content_playlist_t *playlist,
unsigned index);