diff options
author | Yonit Halperin <yhalperi@redhat.com> | 2012-02-29 17:02:28 +0200 |
---|---|---|
committer | Yonit Halperin <yhalperi@redhat.com> | 2012-03-01 08:59:19 +0200 |
commit | d2cd7b2b020da1dc7efe778ddfc4525e31784dbb (patch) | |
tree | acb194c14b9ec9dd4dc50ed1ccb94f40821ecf23 /client | |
parent | 68cdc5488da1a008fa4e8a4447b85aa8ac9c2735 (diff) | |
download | spice-d2cd7b2b020da1dc7efe778ddfc4525e31784dbb.tar.gz spice-d2cd7b2b020da1dc7efe778ddfc4525e31784dbb.tar.xz spice-d2cd7b2b020da1dc7efe778ddfc4525e31784dbb.zip |
client X11: support volume keys when evdev is in use
Add support for sending volume keys scancodes to the guest
RHBZ #552539
Signed-off-by: Yonit Halperin <yhalperi@redhat.com>
Diffstat (limited to 'client')
-rw-r--r-- | client/x11/red_window.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/client/x11/red_window.cpp b/client/x11/red_window.cpp index b16249ea..fda90d59 100644 --- a/client/x11/red_window.cpp +++ b/client/x11/red_window.cpp @@ -186,6 +186,9 @@ enum EvdevKeyCode { EVDEV_KEYCODE_PAGE_DOWN, EVDEV_KEYCODE_INSERT, EVDEV_KEYCODE_DELETE, + EVDEV_KEYCODE_MUTE = 121, + EVDEV_KEYCODE_VOLUME_DOWN = 122, + EVDEV_KEYCODE_VOLUME_UP = 123, EVDEV_KEYCODE_PAUSE = 127, EVDEV_KEYCODE_HANGUL = 130, EVDEV_KEYCODE_HANGUL_HANJA, @@ -456,6 +459,9 @@ static void init_evdev_map() { #define KEYMAP(key_code, red_key) keycode_map[EVDEV_##key_code] = red_key INIT_MAP; + KEYMAP(KEYCODE_MUTE, REDKEY_MUTE); + KEYMAP(KEYCODE_VOLUME_DOWN, REDKEY_VOLUME_DOWN); + KEYMAP(KEYCODE_VOLUME_UP, REDKEY_VOLUME_UP); #undef KEYMAP } |