13 layoutRoot =
GetGame().GetWorkspace().CreateWidgets(
"gui/layouts/day_z_options_controls_preset.layout");
15 m_schemes_list = TextListboxWidget.Cast( layoutRoot.FindAnyWidget(
"PresetListboxWidget") );
17 int c =
GetGame().GetInput().GetProfilesCount();
18 for (
int i = 0; i < c; i++)
21 GetGame().GetInput().GetProfileName(i, tmp);
22 m_schemes_list.AddItem(tmp, NULL, 0);
25 i =
GetGame().GetInput().GetCurrentProfile();
28 m_schemes_list.SelectRow(i);
36 super.OnClick(w,
x,
y, button);
38 switch (w.GetUserID())
46 int index = m_schemes_list.GetSelectedRow();
49 GetGame().GetInput().SetProfile(index);
50 GetGame().GetMission().GetOnInputPresetChanged().Invoke();
60 private TextListboxWidget m_schemes_list;