diff options
author | Christopher Faylor <me@cgf.cx> | 2000-07-29 19:07:15 +0000 |
---|---|---|
committer | Christopher Faylor <me@cgf.cx> | 2000-07-29 19:07:15 +0000 |
commit | 751669bbb0d859e9de871c6964c8ae8bab32f3d7 (patch) | |
tree | 822185f5a3cf19b3c1167d0090ae41d20ff6fa30 /winsup/cygwin/fhandler_console.cc | |
parent | af5153a036ede09a399ecd1a241bbba02b83d3e8 (diff) | |
download | cygnal-751669bbb0d859e9de871c6964c8ae8bab32f3d7.tar.gz cygnal-751669bbb0d859e9de871c6964c8ae8bab32f3d7.tar.bz2 cygnal-751669bbb0d859e9de871c6964c8ae8bab32f3d7.zip |
* fhandler_console.cc: Add VK_DIVIDE detection. Return virtual keycode if it
is not detected and it is less than ' '.
Diffstat (limited to 'winsup/cygwin/fhandler_console.cc')
-rw-r--r-- | winsup/cygwin/fhandler_console.cc | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/winsup/cygwin/fhandler_console.cc b/winsup/cygwin/fhandler_console.cc index 7e266ab8d..5ee8e9a58 100644 --- a/winsup/cygwin/fhandler_console.cc +++ b/winsup/cygwin/fhandler_console.cc @@ -1297,6 +1297,8 @@ static struct { {VK_NUMPAD5, {"\033[G", NULL, NULL, NULL}}, {VK_CLEAR, {"\033[G", NULL, NULL, NULL}}, {'6', {NULL, NULL, "\036", NULL}}, + /* FIXME: Should this be \033OQ? */ + {VK_DIVIDE, {"/", "/", "/", "/"}}, {0, {"", NULL, NULL, NULL}} }; @@ -1322,6 +1324,13 @@ get_nonascii_key (INPUT_RECORD& input_rec) if (input_rec.Event.KeyEvent.wVirtualKeyCode == keytable[i].vk) return keytable[i].val[modifier_index]; + if (input_rec.Event.KeyEvent.wVirtualKeyCode < ' ') + { + /* FIXME: Probably not thread-safe */ + static char buf[2]; + buf[0] = input_rec.Event.KeyEvent.wVirtualKeyCode; + return buf; + } return NULL; } |