aboutsummaryrefslogtreecommitdiff
path: root/ui/input-linux.c
diff options
context:
space:
mode:
authorFabian Lesniak <fabian@lesniak-it.de>2016-12-06 20:00:07 +0100
committerGerd Hoffmann <kraxel@redhat.com>2017-01-31 08:14:51 +0100
commit1266b68c6e3af7f7bd53edcba1ee12cec07cdefe (patch)
tree01baec7e37cfd4110222d1b8455107125b62d7fe /ui/input-linux.c
parent8b0caab07bf0056f44b52eb335faa45f07b7e1a6 (diff)
ui: add support for mice with extra/side buttons
Adds input event generation for BTN_SIDE and BTN_EXTRA events to gtk and input-linux methods. Signed-off-by: Fabian Lesniak <fabian@lesniak-it.de> Message-id: 20161206190007.7539-4-fabian@lesniak-it.de Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'ui/input-linux.c')
-rw-r--r--ui/input-linux.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/ui/input-linux.c b/ui/input-linux.c
index f345317794..ac31f47719 100644
--- a/ui/input-linux.c
+++ b/ui/input-linux.c
@@ -291,6 +291,12 @@ static void input_linux_handle_mouse(InputLinux *il, struct input_event *event)
qemu_input_queue_btn(NULL, INPUT_BUTTON_WHEEL_DOWN,
event->value);
break;
+ case BTN_SIDE:
+ qemu_input_queue_btn(NULL, INPUT_BUTTON_SIDE, event->value);
+ break;
+ case BTN_EXTRA:
+ qemu_input_queue_btn(NULL, INPUT_BUTTON_EXTRA, event->value);
+ break;
};
break;
case EV_REL: