forked from Bananymous/banan-os
Kernel: Fix toggleable modifier keys and add two more keys
This commit is contained in:
parent
c1f0704fa8
commit
d2c0718f7d
|
@ -59,7 +59,7 @@ namespace Kernel::Input
|
|||
Equals, QuestionMark, Plus, BackSlash, Acute, BackTick, TwoDots, Cedilla, Backspace, AtSign, Pound, Dollar, Euro,
|
||||
Escape, Tab, CapsLock, LeftShift, LeftCtrl, Super, LeftAlt, RightAlt, AltGr = RightAlt, RightCtrl, RightShift,
|
||||
SingleQuote, Asterix, Caret, Tilde, ArrowUp, ArrowDown, ArrowLeft, ArrowRight,
|
||||
Comma, Semicolon, Period, Colon, Hyphen, Underscore, NumLock, ScrollLock, LessThan, GreaterThan, Pipe,
|
||||
Comma, Semicolon, Period, Colon, Hyphen, Underscore, NumLock, ScrollLock, LessThan, GreaterThan, Pipe, Negation, BrokenBar,
|
||||
Numpad0, Numpad1, Numpad2, Numpad3, Numpad4, Numpad5, Numpad6, Numpad7, Numpad8, Numpad9,
|
||||
NumpadPlus, NumpadMinus, NumpadMultiply, NumpadDivide, NumpadEnter, NumpadDecimal,
|
||||
VolumeMute, VolumeUp, VolumeDown, Calculator, MediaPlayPause, MediaStop, MediaPrevious, MediaNext,
|
||||
|
|
|
@ -24,7 +24,7 @@ namespace Kernel::Input
|
|||
"=", "?", "+", "\\", "´", "`", "¨", "¸", nullptr, "@", "£", "$", "€",
|
||||
nullptr, "\t", nullptr, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr,
|
||||
"'", "*", "^", "~", nullptr, nullptr, nullptr, nullptr,
|
||||
",", ";", ".", ":", "-", "_", nullptr, nullptr, "<", ">", "|",
|
||||
",", ";", ".", ":", "-", "_", nullptr, nullptr, "<", ">", "|", "¬", "¦",
|
||||
"0", "1", "2", "3", "4", "5", "6", "7", "8", "9",
|
||||
"+", "-", "*", "/", nullptr, ",",
|
||||
nullptr, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr,
|
||||
|
@ -43,7 +43,7 @@ namespace Kernel::Input
|
|||
"=", "?", "+", "\\", "´", "`", "¨", "¸", nullptr, "@", "£", "$", "€",
|
||||
nullptr, "\t", nullptr, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr,
|
||||
"'", "*", "^", "~", nullptr, nullptr, nullptr, nullptr,
|
||||
",", ";", ".", ":", "-", "_", nullptr, nullptr, "<", ">", "|",
|
||||
",", ";", ".", ":", "-", "_", nullptr, nullptr, "<", ">", "|", "¬", "¦",
|
||||
"0", "1", "2", "3", "4", "5", "6", "7", "8", "9",
|
||||
"+", "-", "*", "/", nullptr, ",",
|
||||
nullptr, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr,
|
||||
|
|
|
@ -205,6 +205,7 @@ namespace Kernel::Input
|
|||
TRY(s_name_to_key.insert("BackSlash"sv, Key::BackSlash));
|
||||
TRY(s_name_to_key.insert("Backspace"sv, Key::Backspace));
|
||||
TRY(s_name_to_key.insert("BackTick"sv, Key::BackTick));
|
||||
TRY(s_name_to_key.insert("BrokenBar"sv, Key::BrokenBar));
|
||||
TRY(s_name_to_key.insert("C"sv, Key::C));
|
||||
TRY(s_name_to_key.insert("Calculator"sv, Key::Calculator));
|
||||
TRY(s_name_to_key.insert("CapsLock"sv, Key::CapsLock));
|
||||
|
@ -276,6 +277,7 @@ namespace Kernel::Input
|
|||
TRY(s_name_to_key.insert("MediaPrevious"sv, Key::MediaPrevious));
|
||||
TRY(s_name_to_key.insert("MediaStop"sv, Key::MediaStop));
|
||||
TRY(s_name_to_key.insert("N"sv, Key::N));
|
||||
TRY(s_name_to_key.insert("Negation"sv, Key::Negation));
|
||||
TRY(s_name_to_key.insert("None"sv, Key::None));
|
||||
TRY(s_name_to_key.insert("NumLock"sv, Key::NumLock));
|
||||
TRY(s_name_to_key.insert("Numpad0"sv, Key::Numpad0));
|
||||
|
|
|
@ -150,7 +150,7 @@ namespace Kernel::Input
|
|||
m_modifiers |= modifier_mask;
|
||||
}
|
||||
|
||||
if (toggle_mask)
|
||||
if (toggle_mask && !released)
|
||||
{
|
||||
m_modifiers ^= toggle_mask;
|
||||
update_leds();
|
||||
|
|
Loading…
Reference in New Issue