(RMenu) Take out RMENU_LOW_RAM_MODE

This commit is contained in:
twinaphex 2013-04-13 16:32:40 +02:00
parent fa253e6311
commit 53d5678b85
4 changed files with 4 additions and 72 deletions

View File

@ -229,9 +229,6 @@ static void rmenu_gfx_init(void)
texture_image_load("D:\\Media\\menuMainRomSelectPanel.png", menu_panel);
#endif
if (g_extern.lifecycle_mode_state & (1ULL << MODE_MENU_LOW_RAM_MODE_ENABLE))
return;
texture_image_load(g_extern.menu_texture_path, menu_texture);
}
@ -389,20 +386,6 @@ static void populate_setting_item(void *data, unsigned input)
strlcpy(current_item->setting_text, fname, sizeof(current_item->setting_text));
strlcpy(current_item->comment, "INFO - Select a skin for the menu.", sizeof(current_item->comment));
break;
case SETTING_EMU_LOW_RAM_MODE_ENABLE:
strlcpy(current_item->text, "Low RAM Mode", sizeof(current_item->text));
if (g_extern.lifecycle_mode_state & (1ULL <<MODE_MENU_LOW_RAM_MODE_ENABLE) ||
g_extern.lifecycle_mode_state & (1ULL << MODE_MENU_LOW_RAM_MODE_ENABLE_PENDING))
{
strlcpy(current_item->setting_text, "ON", sizeof(current_item->setting_text));
strlcpy(current_item->comment, "INFO - Will load skin at startup.", sizeof(current_item->comment));
}
else
{
strlcpy(current_item->setting_text, "OFF", sizeof(current_item->setting_text));
strlcpy(current_item->comment, "INFO - Enable this and restart to free up more RAM.", sizeof(current_item->comment));
}
break;
case SETTING_FONT_SIZE:
strlcpy(current_item->text, "Font Size", sizeof(current_item->text));
snprintf(current_item->setting_text, sizeof(current_item->setting_text), "%f", g_settings.video.font_size);
@ -1609,35 +1592,6 @@ static int set_setting_action(uint8_t menu_type, unsigned switchvalue, uint64_t
}
}
break;
case SETTING_EMU_LOW_RAM_MODE_ENABLE:
if ((input & (1ULL << RMENU_DEVICE_NAV_LEFT)) || (input & (1ULL << RMENU_DEVICE_NAV_RIGHT)) || (input & (1ULL << RMENU_DEVICE_NAV_B)))
{
if (!(g_extern.lifecycle_mode_state & (1ULL << MODE_MENU_LOW_RAM_MODE_ENABLE_PENDING)))
{
if (g_extern.lifecycle_mode_state & (1ULL << MODE_MENU_LOW_RAM_MODE_ENABLE))
g_extern.lifecycle_mode_state &= ~(1ULL << MODE_MENU_LOW_RAM_MODE_ENABLE);
else
g_extern.lifecycle_mode_state |= (1ULL << MODE_MENU_LOW_RAM_MODE_ENABLE_PENDING);
if (g_extern.lifecycle_mode_state & (1ULL << MODE_INFO_DRAW))
msg_queue_push(g_extern.msg_queue, "INFO - You need to restart RetroArch.", 1, 180);
}
}
if (input & (1ULL << RMENU_DEVICE_NAV_START))
{
if (!(g_extern.lifecycle_mode_state & (1ULL << MODE_MENU_LOW_RAM_MODE_ENABLE)))
{
if (!(g_extern.lifecycle_mode_state & (1ULL << MODE_MENU_LOW_RAM_MODE_ENABLE_PENDING)))
{
g_extern.lifecycle_mode_state |= (1ULL << MODE_MENU_LOW_RAM_MODE_ENABLE);
g_extern.lifecycle_mode_state |= (1ULL << MODE_MENU_LOW_RAM_MODE_ENABLE_PENDING);
if (g_extern.lifecycle_mode_state & (1ULL << MODE_INFO_DRAW))
msg_queue_push(g_extern.msg_queue, "INFO - You need to restart RetroArch.", 1, 180);
}
}
}
break;
case SETTING_FONT_SIZE:
if (input & (1ULL << RMENU_DEVICE_NAV_LEFT))
{
@ -3534,14 +3488,11 @@ bool menu_iterate(void)
g_extern.lifecycle_mode_state &= ~((1ULL << MODE_MENU_INGAME) | (1ULL << MODE_MENU_INGAME_EXIT));
}
if (!(g_extern.lifecycle_mode_state & (1ULL << MODE_MENU_LOW_RAM_MODE_ENABLE)))
if (driver.video_poke && driver.video_poke->set_texture_enable)
{
if (driver.video_poke && driver.video_poke->set_texture_enable)
{
driver.video_poke->set_texture_frame(driver.video_data, menu_texture->pixels,
true, menu_texture->width, menu_texture->height, 1.0f);
driver.video_poke->set_texture_enable(driver.video_data, menu_bg_show);
}
driver.video_poke->set_texture_frame(driver.video_data, menu_texture->pixels,
true, menu_texture->width, menu_texture->height, 1.0f);
driver.video_poke->set_texture_enable(driver.video_data, menu_bg_show);
}
// draw last frame for loading messages

View File

@ -110,7 +110,6 @@ enum
SETTING_EMU_CURRENT_SAVE_STATE_SLOT,
SETTING_EMU_SHOW_DEBUG_INFO_MSG,
SETTING_EMU_SHOW_INFO_MSG,
SETTING_EMU_LOW_RAM_MODE_ENABLE,
SETTING_EMU_SKIN,
SETTING_RARCH_DEFAULT_EMU,
SETTING_QUIT_RARCH,

View File

@ -110,8 +110,6 @@ enum menu_enums
MODE_MENU_PREINIT,
MODE_MENU_INGAME,
MODE_MENU_INGAME_EXIT,
MODE_MENU_LOW_RAM_MODE_ENABLE,
MODE_MENU_LOW_RAM_MODE_ENABLE_PENDING,
MODE_INFO_DRAW,
MODE_FPS_DRAW,
MODE_EXTLAUNCH_SALAMANDER,

View File

@ -482,13 +482,6 @@ 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.menu_texture_path, tmp_str, sizeof(g_extern.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))
@ -1152,15 +1145,6 @@ bool config_save_file(const char *path)
config_set_int(conf, "input_autodetect_icade_profile_pad4", input.icade_profile[3]);
#endif
#ifdef HAVE_RMENU
if (g_extern.lifecycle_mode_state & (1ULL << MODE_MENU_LOW_RAM_MODE_ENABLE))
config_set_int(conf, "rmenu_low_ram_mode_enable", 1);
else if (g_extern.lifecycle_mode_state & (1ULL << MODE_MENU_LOW_RAM_MODE_ENABLE_PENDING))
config_set_int(conf, "rmenu_low_ram_mode_enable", 1);
else
config_set_int(conf, "rmenu_low_ram_mode_enable", 0);
#endif
config_set_bool(conf, "gamma_correction", g_extern.console.screen.gamma_correction);
#ifdef _XBOX1
config_set_int(conf, "sound_volume_level", g_extern.console.sound.volume_level);