aboutsummaryrefslogtreecommitdiff
path: root/hw/input
diff options
context:
space:
mode:
authorNoah Bergbauer <noah@statshelix.com>2021-11-26 15:04:37 +0100
committerLaurent Vivier <laurent@vivier.eu>2022-02-22 17:15:36 +0100
commit1e2d555846226a9e5fb1052fe8ba6f30480f33a9 (patch)
tree29e49887ef36ac8cdad001fda84e5eeef2ef8016 /hw/input
parenteb3cb751c9fbba3ba3dc640ff7f7cb4fe6a55829 (diff)
downloadqemu-1e2d555846226a9e5fb1052fe8ba6f30480f33a9.zip
qemu-1e2d555846226a9e5fb1052fe8ba6f30480f33a9.tar.gz
qemu-1e2d555846226a9e5fb1052fe8ba6f30480f33a9.tar.bz2
hid: Implement support for side and extra buttons
Simply set the respective bits and update the descriptor accordingly. Signed-off-by: Noah Bergbauer <noah@statshelix.com> Acked-by: Gerd Hoffmann <kraxel@redhat.com> Message-Id: <20211126140437.79745-1-noah@statshelix.com> Signed-off-by: Laurent Vivier <laurent@vivier.eu>
Diffstat (limited to 'hw/input')
-rw-r--r--hw/input/hid.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/hw/input/hid.c b/hw/input/hid.c
index 8aab052..e7ecebd 100644
--- a/hw/input/hid.c
+++ b/hw/input/hid.c
@@ -114,6 +114,8 @@ static void hid_pointer_event(DeviceState *dev, QemuConsole *src,
[INPUT_BUTTON_LEFT] = 0x01,
[INPUT_BUTTON_RIGHT] = 0x02,
[INPUT_BUTTON_MIDDLE] = 0x04,
+ [INPUT_BUTTON_SIDE] = 0x08,
+ [INPUT_BUTTON_EXTRA] = 0x10,
};
HIDState *hs = (HIDState *)dev;
HIDPointerEvent *e;