mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-06-10 18:10:56 +09: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
Notes:
sideshowbarker
2024-07-19 05:56:59 +09:00
Author: https://github.com/bugaevc
Commit: 66c6e0035e
Pull-request: https://github.com/SerenityOS/serenity/pull/2445
Issue: https://github.com/SerenityOS/serenity/issues/91
Reviewed-by: https://github.com/alimpfard
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;
|
||||
}
|
||||
|
||||
if (!character) {
|
||||
// Probably a modifier being pressed.
|
||||
return;
|
||||
}
|
||||
|
||||
if (shift && key == KeyCode::Key_Tab) {
|
||||
emit_string("\033[Z");
|
||||
return;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue