mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 02:07:36 +00:00
Kernel: Allow remapping Caps Lock to Control (#6883)
We use a global setting to determine if Caps Lock should be remapped to Control because we don't care how keyboard events come in, just that they should be massaged into different scan codes. The `proc` filesystem is able to manipulate this global variable using the `sysctl` utility like so: ``` # sysctl caps_lock_to_ctrl=1 ```
This commit is contained in:
parent
18d344609f
commit
0f89e47a1a
5 changed files with 18 additions and 1 deletions
|
@ -53,6 +53,7 @@ protected:
|
|||
virtual const char* class_name() const override { return "KeyboardDevice"; }
|
||||
|
||||
u8 m_modifiers { 0 };
|
||||
bool m_caps_lock_to_ctrl_pressed { false };
|
||||
bool m_caps_lock_on { false };
|
||||
bool m_num_lock_on { false };
|
||||
bool m_has_e0_prefix { false };
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue