mirror of
https://github.com/wichtounet/thor-os.git
synced 2025-09-17 16:51:33 -04:00
Store the keycode rather than raw key
This commit is contained in:
parent
2b941a95ad
commit
951b0a656c
@ -306,7 +306,7 @@ char keyboard::shift_key_to_ascii(uint8_t key){
|
||||
return shifted_qwertz[key];
|
||||
}
|
||||
|
||||
keycode raw_key_to_keycode(uint8_t key){
|
||||
keycode keyboard::raw_key_to_keycode(uint8_t key){
|
||||
if(key & 0x80){
|
||||
key &= ~(0x80);
|
||||
return released_codes[key];
|
||||
|
@ -72,7 +72,8 @@ void stdio::virtual_terminal::send_input(char key){
|
||||
} else {
|
||||
// The complete processing of the key will be done by the
|
||||
// userspace program
|
||||
raw_buffer.push(key);
|
||||
auto code = keyboard::raw_key_to_keycode(key);
|
||||
raw_buffer.push(static_cast<size_t>(code));
|
||||
|
||||
if(!input_queue.empty()){
|
||||
input_queue.wake_up();
|
||||
|
Loading…
x
Reference in New Issue
Block a user