mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Different implementation of KeyPress::operator==
Fixes some key mapping issues.
This commit is contained in:
parent
4547ace59a
commit
1bbfd0b6d2
1 changed files with 2 additions and 1 deletions
|
@ -36,7 +36,8 @@ public:
|
||||||
|
|
||||||
bool operator==(const KeyPress &o) const
|
bool operator==(const KeyPress &o) const
|
||||||
{
|
{
|
||||||
return valid_kcode(Key) ? Key == o.Key : Char == o.Char;
|
return (Char > 0 && Char == o.Char) ||
|
||||||
|
(valid_kcode(Key) && Key == o.Key);
|
||||||
}
|
}
|
||||||
|
|
||||||
const char *sym() const;
|
const char *sym() const;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue