int i;
#define ADD_TO_W_LIST(pred) \
- FOREACH(Weapons, it != WEP_Null, LAMBDA( \
+ FOREACH(Weapons, it != WEP_Null, { \
if (it.impulse != imp) continue; \
if (!(pred)) continue; \
w_list = strcat(w_list, it.m_name, " / "); \
- ))
+ })
for(int imp = 1; imp <= 9; ++imp)
{
for(int i = 0; i < MAX_KEYBINDS; ++i)
{
- if(Xonotic_KeyBinds_Functions[i])
- strunzone(Xonotic_KeyBinds_Functions[i]);
- Xonotic_KeyBinds_Functions[i] = string_null;
- if(Xonotic_KeyBinds_Descriptions[i])
- strunzone(Xonotic_KeyBinds_Descriptions[i]);
- Xonotic_KeyBinds_Descriptions[i] = string_null;
+ strfree(Xonotic_KeyBinds_Functions[i]);
+ strfree(Xonotic_KeyBinds_Descriptions[i]);
}
Xonotic_KeyBinds_Count = 0;
}
}
return r;
}
+
void XonoticKeyBinder_drawListBoxItem(entity me, int i, vector absSize, bool isSelected, bool isFocused)
{
string s;
{
if(s != "")
s = strcat(s, ", ");
- s = strcat(s, keynumtostring(k));
+ s = strcat(s, translate_key(keynumtostring(k)));
}
}
s = draw_TextShortenToWidth(s, me.columnKeysSize, 0, me.realFontSize);