From 512a6813453f8785778284036f250f2201b7ebc0 Mon Sep 17 00:00:00 2001 From: twinaphex Date: Tue, 30 Oct 2018 09:11:07 -0700 Subject: [PATCH] Use runloop_get_libretro_system_info in more places - clean some code up (cherry picked from commit a662b62d192787543f504f4535da523991c906ba) --- ui/drivers/ui_cocoa.m | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-) diff --git a/ui/drivers/ui_cocoa.m b/ui/drivers/ui_cocoa.m index 2a99d15528..2a4561a584 100644 --- a/ui/drivers/ui_cocoa.m +++ b/ui/drivers/ui_cocoa.m @@ -293,13 +293,9 @@ static char** waiting_argv; { if (filenames.count == 1 && [filenames objectAtIndex:0]) { - rarch_system_info_t *info = runloop_get_system_info(); - struct retro_system_info *system = &info->info; + struct retro_system_info *system = runloop_get_libretro_system_info(); NSString *__core = [filenames objectAtIndex:0]; - const char *core_name = NULL; - - if (system) - core_name = system->library_name; + const char *core_name = system ? system->library_name : NULL; if (core_name) { @@ -369,12 +365,8 @@ static void open_document_handler(ui_browser_window_state_t *state, bool result) if (!result) return; - rarch_system_info_t *info = runloop_get_system_info(); - struct retro_system_info *system = &info->info; - const char *core_name = NULL; - - if (system) - core_name = system->library_name; + struct retro_system_info *system = runloop_get_libretro_system_info(); + const char *core_name = system ? system->library_name : NULL; path_set(RARCH_PATH_CONTENT, state->result);