1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

term: fix errors in input_windows.c.v (#15966)

This commit is contained in:
yuyi 2022-10-05 18:24:22 +08:00 committed by GitHub
parent 6ccdf89546
commit f0871b87a4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -165,11 +165,11 @@ fn (mut ctx Context) parse_events() {
C.VK_DOWN { KeyCode.down } C.VK_DOWN { KeyCode.down }
C.VK_INSERT { KeyCode.insert } C.VK_INSERT { KeyCode.insert }
C.VK_DELETE { KeyCode.delete } C.VK_DELETE { KeyCode.delete }
65...90 { KeyCode(ch + 32) } // letters 65...90 { unsafe { KeyCode(ch + 32) } } // letters
91...93 { KeyCode.null } // special keys 91...93 { KeyCode.null } // special keys
96...105 { KeyCode(ch - 48) } // numpad numbers 96...105 { unsafe { KeyCode(ch - 48) } } // numpad numbers
112...135 { KeyCode(ch + 178) } // f1 - f24 112...135 { unsafe { KeyCode(ch + 178) } } // f1 - f24
else { KeyCode(ascii) } else { unsafe { KeyCode(ascii) } }
} }
mut modifiers := Modifiers{} mut modifiers := Modifiers{}