]> git.ipfire.org Git - thirdparty/qemu.git/commit
vnc: fix capslock tracking logic.
authorGerd Hoffmann <kraxel@redhat.com>
Fri, 11 Dec 2009 10:25:07 +0000 (11:25 +0100)
committerAnthony Liguori <aliguori@us.ibm.com>
Sat, 12 Dec 2009 14:17:30 +0000 (08:17 -0600)
commitd707483ce33847aa101a208478d6fe01b56b6ecf
tree5e64e21c56f959fd1c6dba60c07bab52288e1e7c
parente2deb622c29e15603d5f192c9f5378d2568d0749
vnc: fix capslock tracking logic.

The capslock tracking logic added by commit
6b1325029d80455b9da7cd7bd84a88cb915b867c doesn't work correctly for vnc
clients without EXT_KEY_EVENT support.  The reason is that qemu converts
keysyms for letters to lowercase for the keysym2scancode lookup.  It
then also passes the lowercase value down to do_key_event(), but the
capslock tracking code needs it with the correct case to work properly.

This patch adds a new variable for the lowercase keysym so we'll keep
the unmodified value for do_key_event().

The keysym2scancode is not needed with EXT_KEY_EVENT capable clients
like any app based on the gtk-vnc widget, so I missed that case in
testing ...

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
(cherry picked from commit 4a93fe17081c7ae7f4d5607b266ca384d328986c)
vnc.c