mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Clean up key names handling
Constify keycode and move the static array of localizable names from the guiKeyChangeMenu header to the implementation file, changing its name.
This commit is contained in:
parent
72e4c8f523
commit
eb255e6870
4 changed files with 87 additions and 86 deletions
|
@ -206,7 +206,7 @@ static const char *KeyNames[] =
|
|||
"-", "-", "-", "-", "-", "-", "-", "-", "Attn", "CrSel", "ExSel",
|
||||
"Erase OEF", "Play", "Zoom", "PA1", "OEM Clear", "-" };
|
||||
|
||||
std::string keycode_to_keyname(s32 keycode)
|
||||
const std::string &keycode_to_keyname(s32 keycode)
|
||||
{
|
||||
return KeyNames[keycode];
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue