revert commit 6cf8a72d49; Windows fixes getch bug
This commit is contained in:
parent
c9f184401c
commit
7740b12f21
1 changed files with 1 additions and 4 deletions
|
|
@ -727,10 +727,7 @@ proc getch*(): char =
|
|||
doAssert(readConsoleInput(fd, addr(keyEvent), 1, addr(numRead)) != 0)
|
||||
if numRead == 0 or keyEvent.eventType != 1 or keyEvent.bKeyDown == 0:
|
||||
continue
|
||||
if keyEvent.uChar == 0:
|
||||
return char(keyEvent.wVirtualKeyCode)
|
||||
else:
|
||||
return char(keyEvent.uChar)
|
||||
return char(keyEvent.uChar)
|
||||
else:
|
||||
let fd = getFileHandle(stdin)
|
||||
var oldMode: Termios
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue