mirror of
https://github.com/libretro/RetroArch
synced 2025-01-25 06:35:30 +00:00
(360) Programmatically fill in XUI list for 'Settings'
This commit is contained in:
parent
7d075514b3
commit
d481bc61fc
@ -1003,14 +1003,24 @@ HRESULT CRetroArchSettings::OnInit(XUIMessageInit * pInitData, BOOL& bHandled)
|
||||
GetChildById(L"XuiSettingsList", &m_settingslist);
|
||||
GetChildById(L"XuiBackButton", &m_back);
|
||||
|
||||
XuiListDeleteItems(m_settingslist, 0, XuiListGetItemCount(m_settingslist));
|
||||
|
||||
XuiListInsertItems(m_settingslist, 0, 1);
|
||||
XuiListSetText(m_settingslist, SETTING_EMU_REWIND_ENABLED, g_settings.rewind_enable ? L"Rewind: ON" : L"Rewind: OFF");
|
||||
XuiListSetText(m_settingslist, SETTING_EMU_SHOW_INFO_MSG, (g_extern.lifecycle_mode_state & (1ULL << MODE_INFO_DRAW)) ? L"Info Messages: ON" : L"Info Messages: OFF");
|
||||
XuiListSetText(m_settingslist, SETTING_EMU_SHOW_DEBUG_INFO_MSG, (g_extern.lifecycle_mode_state & (1ULL << MODE_FPS_DRAW)) ? L"Debug Info Messages: ON" : L"Debug Info messages: OFF");
|
||||
XuiListSetText(m_settingslist, SETTING_GAMMA_CORRECTION_ENABLED, g_extern.console.screen.gamma_correction ? L"Gamma Correction: ON" : L"Gamma correction: OFF");
|
||||
XuiListSetText(m_settingslist, SETTING_HW_TEXTURE_FILTER, g_settings.video.smooth ? L"Default Filter: Linear" : L"Default Filter: Nearest");
|
||||
|
||||
menu_settings_create_menu_item_label_w(strw_buffer, S_LBL_REWIND_GRANULARITY, sizeof(strw_buffer));
|
||||
XuiListInsertItems(m_settingslist, 1, 1);
|
||||
XuiListSetText(m_settingslist, SETTING_EMU_REWIND_GRANULARITY, strw_buffer);
|
||||
|
||||
XuiListInsertItems(m_settingslist, 2, 1);
|
||||
XuiListSetText(m_settingslist, SETTING_EMU_SHOW_INFO_MSG, (g_extern.lifecycle_mode_state & (1ULL << MODE_INFO_DRAW)) ? L"Info Messages: ON" : L"Info Messages: OFF");
|
||||
XuiListInsertItems(m_settingslist, 3, 1);
|
||||
XuiListSetText(m_settingslist, SETTING_EMU_SHOW_DEBUG_INFO_MSG, (g_extern.lifecycle_mode_state & (1ULL << MODE_FPS_DRAW)) ? L"Debug Info Messages: ON" : L"Debug Info messages: OFF");
|
||||
XuiListInsertItems(m_settingslist, 4, 1);
|
||||
XuiListSetText(m_settingslist, SETTING_GAMMA_CORRECTION_ENABLED, g_extern.console.screen.gamma_correction ? L"Gamma Correction: ON" : L"Gamma correction: OFF");
|
||||
XuiListInsertItems(m_settingslist, 5, 1);
|
||||
XuiListSetText(m_settingslist, SETTING_HW_TEXTURE_FILTER, g_settings.video.smooth ? L"Default Filter: Linear" : L"Default Filter: Nearest");
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -27,8 +27,6 @@ enum
|
||||
SETTING_EMU_SHOW_DEBUG_INFO_MSG,
|
||||
SETTING_GAMMA_CORRECTION_ENABLED,
|
||||
SETTING_HW_TEXTURE_FILTER,
|
||||
SETTING_ENABLE_SRAM_PATH,
|
||||
SETTING_ENABLE_STATE_PATH,
|
||||
};
|
||||
|
||||
enum
|
||||
|
@ -30,13 +30,6 @@
|
||||
<Width>683.120056</Width>
|
||||
<Height>383.040009</Height>
|
||||
<Position>44.880005,64.959991,0.000000</Position>
|
||||
<ItemsText>Rewind:
|
||||
Rewind granularity:
|
||||
Info messages:
|
||||
Debug info messages:
|
||||
Gamma Correction:
|
||||
Hardware filtering shader #1:
|
||||
</ItemsText>
|
||||
</Properties>
|
||||
<XuiListItem>
|
||||
<Properties>
|
||||
@ -302,6 +295,18 @@ Hardware filtering shader #1:
|
||||
<InterItemSpacing>0.000000,10.000000,0.000000</InterItemSpacing>
|
||||
</Properties>
|
||||
</XuiListItem>
|
||||
<XuiListItem>
|
||||
<Properties>
|
||||
<Id>control_ListItem</Id>
|
||||
<Width>226.000000</Width>
|
||||
<Height>45.000000</Height>
|
||||
<Position>7.000000,22.000000,0.000000</Position>
|
||||
<Anchor>5</Anchor>
|
||||
<Show>false</Show>
|
||||
<Visual>XuiButton</Visual>
|
||||
<InterItemSpacing>0.000000,10.000000,0.000000</InterItemSpacing>
|
||||
</Properties>
|
||||
</XuiListItem>
|
||||
</XuiCommonList>
|
||||
<XuiBackButton>
|
||||
<Properties>
|
||||
|
@ -30,13 +30,6 @@
|
||||
<Width>492.000000</Width>
|
||||
<Height>232.720001</Height>
|
||||
<Position>44.880005,64.959991,0.000000</Position>
|
||||
<ItemsText>Rewind:
|
||||
Rewind granularity:
|
||||
Info messages:
|
||||
Debug info messages:
|
||||
Gamma Correction:
|
||||
Hardware filtering shader #1:
|
||||
</ItemsText>
|
||||
</Properties>
|
||||
<XuiListItem>
|
||||
<Properties>
|
||||
@ -278,6 +271,18 @@ Hardware filtering shader #1:
|
||||
<InterItemSpacing>0.000000,10.000000,0.000000</InterItemSpacing>
|
||||
</Properties>
|
||||
</XuiListItem>
|
||||
<XuiListItem>
|
||||
<Properties>
|
||||
<Id>control_ListItem</Id>
|
||||
<Width>226.000000</Width>
|
||||
<Height>45.000000</Height>
|
||||
<Position>7.000000,22.000000,0.000000</Position>
|
||||
<Anchor>5</Anchor>
|
||||
<Show>false</Show>
|
||||
<Visual>XuiButton</Visual>
|
||||
<InterItemSpacing>0.000000,10.000000,0.000000</InterItemSpacing>
|
||||
</Properties>
|
||||
</XuiListItem>
|
||||
</XuiCommonList>
|
||||
<XuiBackButton>
|
||||
<Properties>
|
||||
|
Loading…
x
Reference in New Issue
Block a user