mirror of
https://github.com/saymrwulf/xous-core.git
synced 2026-11-21 09:14:34 +00:00
don't repeat the menu key if it is press-held
This commit is contained in:
parent
96f0a0d2ea
commit
a6af300157
1 changed files with 3 additions and 1 deletions
|
|
@ -544,7 +544,9 @@ mod implementation {
|
||||||
KeyMap::Qwertz => map_qwertz(rc),
|
KeyMap::Qwertz => map_qwertz(rc),
|
||||||
_ => ScanCode {key: None, shift: None, hold: None, alt: None},
|
_ => ScanCode {key: None, shift: None, hold: None, alt: None},
|
||||||
};
|
};
|
||||||
if code.hold == None { // if there isn't a pre-defined meaning if the key is held, it's a repeating key
|
if code.hold == None
|
||||||
|
&& !((rc.r == 5) && (rc.c == 2)) // scan code for the menu key
|
||||||
|
{ // if there isn't a pre-defined meaning if the key is held *and* it's not the menu key: it's a repeating key
|
||||||
if let Some(key) = code.key {
|
if let Some(key) = code.key {
|
||||||
self.repeating_key = Some(key);
|
self.repeating_key = Some(key);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue