diff --git a/frontend/menu/rgui.c b/frontend/menu/rgui.c index 77339550d6..270747b362 100644 --- a/frontend/menu/rgui.c +++ b/frontend/menu/rgui.c @@ -1627,7 +1627,7 @@ RMENU API void menu_init(void) { - rgui = rgui_init("", + rgui = rgui_init(g_settings.rgui_browser_directory, menu_framebuf, RGUI_WIDTH * sizeof(uint16_t), NULL, bitmap_bin); diff --git a/general.h b/general.h index d3195b546a..4902856d0d 100644 --- a/general.h +++ b/general.h @@ -285,6 +285,10 @@ struct settings bool network_cmd_enable; uint16_t network_cmd_port; bool stdin_cmd_enable; + +#ifdef HAVE_RGUI + char rgui_browser_directory[PATH_MAX]; +#endif }; enum rarch_game_type diff --git a/retroarch.cfg b/retroarch.cfg index 02741566f6..966254d48d 100644 --- a/retroarch.cfg +++ b/retroarch.cfg @@ -35,6 +35,9 @@ # Implementations can query for this directory to load BIOSes, system-specific configs, etc. # system_directory = +# Sets start directory for RGUI ROM browser. +# rgui_browser_directory = + #### Video # Video driver to use. "gl", "xvideo", "sdl" diff --git a/settings.c b/settings.c index c52f929f36..a3bd9275cc 100644 --- a/settings.c +++ b/settings.c @@ -504,6 +504,13 @@ bool config_load_file(const char *path) #ifdef HAVE_RMENU if (config_get_path(conf, "menu_texture_path", tmp_str, sizeof(tmp_str))) strlcpy(g_extern.console.menu_texture_path, tmp_str, sizeof(g_extern.console.menu_texture_path)); + + int low_ram_mode = 0; + if (config_get_int(conf, "rmenu_low_ram_mode_enable", &low_ram_mode)) + { + if (low_ram_mode == 1) + g_extern.lifecycle_mode_state |= (1ULL << MODE_MENU_LOW_RAM_MODE_ENABLE); + } #endif if (config_get_bool(conf, "info_msg_enable", &msg_enable)) @@ -671,6 +678,10 @@ bool config_load_file(const char *path) *g_settings.screenshot_directory = '\0'; } +#ifdef HAVE_RGUI + CONFIG_GET_PATH(rgui_browser_directory, "rgui_browser_directory"); +#endif + CONFIG_GET_BOOL(rewind_enable, "rewind_enable"); int buffer_size = 0; @@ -713,13 +724,6 @@ bool config_load_file(const char *path) CONFIG_GET_INT(input.icade_profile[3], "input_autodetect_icade_profile_pad4"); #endif - int low_ram_mode = 0; - if (config_get_int(conf, "rmenu_low_ram_mode_enable", &low_ram_mode)) - { - if (low_ram_mode == 1) - g_extern.lifecycle_mode_state |= (1ULL << MODE_MENU_LOW_RAM_MODE_ENABLE); - } - if (config_get_string(conf, "environment_variables", &g_extern.system.environment)) {