mirror of
https://github.com/CTCaer/RetroArch.git
synced 2025-02-04 02:26:13 +00:00
(Apple) Have apple_rarch_load_content just call rarch_main
This commit is contained in:
parent
d014b7f059
commit
5303e1f094
@ -65,6 +65,10 @@
|
||||
|
||||
#endif
|
||||
|
||||
#if !defined(__APPLE__)
|
||||
#define HAVE_MAIN_LOOP
|
||||
#endif
|
||||
|
||||
static retro_keyboard_event_t key_event;
|
||||
|
||||
#ifdef HAVE_MENU
|
||||
@ -374,6 +378,7 @@ returntype main_entry(signature())
|
||||
free_args(wrap_args, argv_copy, ARRAY_SIZE(argv_copy));
|
||||
free(wrap_args);
|
||||
|
||||
#if defined(HAVE_MAIN_LOOP)
|
||||
#if defined(HAVE_MENU)
|
||||
while (!main_entry_iterate(signature_expand(), args));
|
||||
#else
|
||||
@ -381,6 +386,7 @@ returntype main_entry(signature())
|
||||
#endif
|
||||
|
||||
main_exit(args);
|
||||
#endif
|
||||
|
||||
returnfunc();
|
||||
}
|
||||
|
@ -24,9 +24,11 @@
|
||||
#if defined(ANDROID)
|
||||
#define args_type() struct android_app*
|
||||
#define signature() void* data
|
||||
#define returntype void
|
||||
#else
|
||||
#define args_type() void*
|
||||
#define signature() int argc, char *argv[]
|
||||
#define returntype int
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
@ -35,6 +37,7 @@ extern "C" {
|
||||
|
||||
int main_entry_iterate(signature(), args_type() args);
|
||||
void main_exit(args_type() args);
|
||||
returntype main_entry(signature());
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
@ -84,16 +84,7 @@ void apple_event_basic_command(enum basic_event_t action)
|
||||
|
||||
int apple_rarch_load_content(int *argc, char* argv[])
|
||||
{
|
||||
rarch_main_clear_state();
|
||||
rarch_init_msg_queue();
|
||||
|
||||
if (rarch_main_init(*argc, argv))
|
||||
return 1;
|
||||
|
||||
if (!g_extern.libretro_dummy)
|
||||
menu_rom_history_push_current();
|
||||
|
||||
g_extern.lifecycle_state |= 1ULL << MODE_GAME;
|
||||
rarch_main(*argc, argv);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user