mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 02:27:43 +00:00
LibVT: Fix emitting \0 when pressing a modifier key
This causes the kernel to return EOF, which in turn confuses everything. This is a regression from the LibVT port of VirtualConsole.
This commit is contained in:
parent
52711921c6
commit
66c6e0035e
1 changed files with 5 additions and 0 deletions
|
@ -1046,6 +1046,11 @@ void Terminal::handle_key_press(KeyCode key, u8 character, u8 flags)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!character) {
|
||||||
|
// Probably a modifier being pressed.
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (shift && key == KeyCode::Key_Tab) {
|
if (shift && key == KeyCode::Key_Tab) {
|
||||||
emit_string("\033[Z");
|
emit_string("\033[Z");
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue