summaryrefslogtreecommitdiff
path: root/Kernel/Devices/KeyboardDevice.cpp
diff options
context:
space:
mode:
authorHüseyin ASLITÜRK <asliturk@hotmail.com>2020-05-30 22:16:04 +0300
committerAndreas Kling <kling@serenityos.org>2020-06-03 21:52:40 +0200
commit46b92fa173f92400e5fbe51ae8b6e860807f4420 (patch)
treefb9732e1e2f07a9dd4d6dfa6cbdb4c5cfbab93a0 /Kernel/Devices/KeyboardDevice.cpp
parented208003207882a36432d9c90e223c1dadfb135e (diff)
downloadserenity-46b92fa173f92400e5fbe51ae8b6e860807f4420.zip
Kernel: Add scancode value to KeyEvent
Diffstat (limited to 'Kernel/Devices/KeyboardDevice.cpp')
-rw-r--r--Kernel/Devices/KeyboardDevice.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/Kernel/Devices/KeyboardDevice.cpp b/Kernel/Devices/KeyboardDevice.cpp
index 7c15dc6749..9ac7f7d633 100644
--- a/Kernel/Devices/KeyboardDevice.cpp
+++ b/Kernel/Devices/KeyboardDevice.cpp
@@ -30,8 +30,8 @@
#include <AK/Types.h>
#include <Kernel/Arch/i386/CPU.h>
#include <Kernel/Devices/KeyboardDevice.h>
-#include <Kernel/TTY/VirtualConsole.h>
#include <Kernel/IO.h>
+#include <Kernel/TTY/VirtualConsole.h>
//#define KEYBOARD_DEBUG
@@ -475,6 +475,7 @@ void KeyboardDevice::key_state_changed(u8 raw, bool pressed)
Event event;
event.key = key;
+ event.scancode = m_has_e0_prefix ? 0xe000 + raw : raw;
event.character = static_cast<u8>(character);
event.flags = m_modifiers;
if (pressed)