diff --git a/command_event.c b/command_event.c index a9c80012cd..ca5489cb2f 100644 --- a/command_event.c +++ b/command_event.c @@ -83,7 +83,7 @@ static void event_disk_control_set_eject(bool new_state, bool print_log) runloop_ctl(RUNLOOP_CTL_SYSTEM_INFO_GET, &info); if (info) - control = (const struct retro_disk_control_callback*)&info->disk_control; + control = (const struct retro_disk_control_callback*)&info->disk_control_cb; if (!control || !control->get_num_images) return; @@ -131,7 +131,7 @@ static void event_disk_control_set_index(unsigned idx) runloop_ctl(RUNLOOP_CTL_SYSTEM_INFO_GET, &info); if (info) - control = (const struct retro_disk_control_callback*)&info->disk_control; + control = (const struct retro_disk_control_callback*)&info->disk_control_cb; if (!control || !control->get_num_images) return; @@ -189,7 +189,7 @@ static bool event_disk_control_append_image(const char *path) if (sysinfo) control = (const struct retro_disk_control_callback*) - &sysinfo->disk_control; + &sysinfo->disk_control_cb; if (!control) return false; @@ -1559,11 +1559,11 @@ bool event_cmd_ctl(enum event_command cmd, void *data) return event_disk_control_append_image(path); } case EVENT_CMD_DISK_EJECT_TOGGLE: - if (info && info->disk_control.get_num_images) + if (info && info->disk_control_cb.get_num_images) { const struct retro_disk_control_callback *control = (const struct retro_disk_control_callback*) - &info->disk_control; + &info->disk_control_cb; if (control) { @@ -1577,11 +1577,11 @@ bool event_cmd_ctl(enum event_command cmd, void *data) 1, 120, true); break; case EVENT_CMD_DISK_NEXT: - if (info && info->disk_control.get_num_images) + if (info && info->disk_control_cb.get_num_images) { const struct retro_disk_control_callback *control = (const struct retro_disk_control_callback*) - &info->disk_control; + &info->disk_control_cb; if (!control) return false; @@ -1597,11 +1597,11 @@ bool event_cmd_ctl(enum event_command cmd, void *data) 1, 120, true); break; case EVENT_CMD_DISK_PREV: - if (info && info->disk_control.get_num_images) + if (info && info->disk_control_cb.get_num_images) { const struct retro_disk_control_callback *control = (const struct retro_disk_control_callback*) - &info->disk_control; + &info->disk_control_cb; if (!control) return false; diff --git a/dynamic.c b/dynamic.c index b03560ba87..f9eb0c4a1e 100644 --- a/dynamic.c +++ b/dynamic.c @@ -860,7 +860,7 @@ bool rarch_environment_cb(unsigned cmd, void *data) case RETRO_ENVIRONMENT_SET_DISK_CONTROL_INTERFACE: RARCH_LOG("Environ SET_DISK_CONTROL_INTERFACE.\n"); - system->disk_control = + system->disk_control_cb = *(const struct retro_disk_control_callback*)data; break; @@ -1062,7 +1062,7 @@ bool rarch_environment_cb(unsigned cmd, void *data) cb->stop = driver_location_stop; cb->get_position = driver_location_get_position; cb->set_interval = driver_location_set_interval; - system->location_callback = *cb; + system->location_cb = *cb; location_driver_ctl(RARCH_LOCATION_CTL_UNSET_ACTIVE, NULL); break; diff --git a/location/location_driver.c b/location/location_driver.c index 956cf83df9..4c59b7f752 100644 --- a/location/location_driver.c +++ b/location/location_driver.c @@ -217,8 +217,8 @@ void init_location(void) location_driver_ctl(RARCH_LOCATION_CTL_UNSET_ACTIVE, NULL); } - if (system->location_callback.initialized) - system->location_callback.initialized(); + if (system->location_cb.initialized) + system->location_cb.initialized(); } static void uninit_location(void) @@ -229,8 +229,8 @@ static void uninit_location(void) if (location_data && location_driver) { - if (system->location_callback.deinitialized) - system->location_callback.deinitialized(); + if (system->location_cb.deinitialized) + system->location_cb.deinitialized(); if (location_driver->free) location_driver->free(location_data); diff --git a/menu/cbs/menu_cbs_get_value.c b/menu/cbs/menu_cbs_get_value.c index a17c61fd20..db34caa8d2 100644 --- a/menu/cbs/menu_cbs_get_value.c +++ b/menu/cbs/menu_cbs_get_value.c @@ -632,7 +632,7 @@ static void menu_action_setting_disp_set_label_menu_disk_index( if (!system) return; - control = &system->disk_control; + control = &system->disk_control_cb; if (!control) return; diff --git a/menu/menu_displaylist.c b/menu/menu_displaylist.c index 90356ce0f8..7a99d9265e 100644 --- a/menu/menu_displaylist.c +++ b/menu/menu_displaylist.c @@ -2088,7 +2088,7 @@ static int menu_displaylist_parse_load_content_settings( menu_hash_to_str(MENU_LABEL_CORE_CHEAT_OPTIONS), MENU_SETTING_ACTION, 0, 0); if ( (!rarch_ctl(RARCH_CTL_IS_DUMMY_CORE, NULL)) - && system && system->disk_control.get_num_images) + && system && system->disk_control_cb.get_num_images) menu_entries_push(info->list, menu_hash_to_str(MENU_LABEL_VALUE_DISK_OPTIONS), menu_hash_to_str(MENU_LABEL_DISK_OPTIONS), diff --git a/system.h b/system.h index bcc24f1088..dbb2b0edd6 100644 --- a/system.h +++ b/system.h @@ -40,8 +40,8 @@ typedef struct rarch_system_info const char *input_desc_btn[MAX_USERS][RARCH_FIRST_META_KEY]; char valid_extensions[PATH_MAX_LENGTH]; - struct retro_disk_control_callback disk_control; - struct retro_location_callback location_callback; + struct retro_disk_control_callback disk_control_cb; + struct retro_location_callback location_cb; core_option_manager_t *core_options;