1
0
Fork 0
mirror of https://gitlab.com/sortix/sortix.git synced 2023-02-13 20:55:38 -05:00

Add terminal support for ^L.

This commit is contained in:
Jonas 'Sortie' Termansen 2013-05-29 00:35:29 +02:00
parent ddf3dd329f
commit 871469d443

View file

@ -214,6 +214,17 @@ void LogTerminal::ProcessKeystroke(int kbkey)
return; return;
} }
if ( termmode & TERMMODE_LINEBUFFER && control && kbkey == KBKEY_L )
{
while ( linebuffer.CanBackspace() )
linebuffer.Backspace();
QueueUnicode(KBKEY_ENCODE(KBKEY_ENTER));
QueueUnicode('\n');
QueueUnicode(KBKEY_ENCODE(-KBKEY_ENTER));
Log::PrintF("\e[H\e[2J");
return;
}
uint32_t unikbkey = KBKEY_ENCODE(kbkey); uint32_t unikbkey = KBKEY_ENCODE(kbkey);
QueueUnicode(unikbkey); QueueUnicode(unikbkey);
uint32_t unicode = kblayout->Translate(kbkey); uint32_t unicode = kblayout->Translate(kbkey);