aboutsummaryrefslogtreecommitdiff
path: root/ui/input.c
diff options
context:
space:
mode:
authorSergio Lopez <slp@redhat.com>2023-05-26 13:29:21 +0200
committerMarc-André Lureau <marcandre.lureau@redhat.com>2023-05-28 13:08:25 +0400
commit2bfb10dff2a21e42708aa4aef4bb64e8e3674858 (patch)
treed73da317f73335d5c13bb715acbe492a56e04fa3 /ui/input.c
parent944ae6d9f17c3c6609f8d0832311b7a050d6c4b6 (diff)
downloadqemu-2bfb10dff2a21e42708aa4aef4bb64e8e3674858.zip
qemu-2bfb10dff2a21e42708aa4aef4bb64e8e3674858.tar.gz
qemu-2bfb10dff2a21e42708aa4aef4bb64e8e3674858.tar.bz2
ui: add the infrastructure to support MT events
Add the required infrastructure to support generating multitouch events. Signed-off-by: Sergio Lopez <slp@redhat.com> Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: Markus Armbruster <armbru@redhat.com> Message-Id: <20230526112925.38794-3-slp@redhat.com>
Diffstat (limited to 'ui/input.c')
-rw-r--r--ui/input.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/ui/input.c b/ui/input.c
index f2d1e7a..fc75f13 100644
--- a/ui/input.c
+++ b/ui/input.c
@@ -212,6 +212,7 @@ static void qemu_input_event_trace(QemuConsole *src, InputEvent *evt)
InputKeyEvent *key;
InputBtnEvent *btn;
InputMoveEvent *move;
+ InputMultiTouchEvent *mtt;
if (src) {
idx = qemu_console_get_index(src);
@@ -250,6 +251,11 @@ static void qemu_input_event_trace(QemuConsole *src, InputEvent *evt)
name = InputAxis_str(move->axis);
trace_input_event_abs(idx, name, move->value);
break;
+ case INPUT_EVENT_KIND_MTT:
+ mtt = evt->u.mtt.data;
+ name = InputAxis_str(mtt->axis);
+ trace_input_event_mtt(idx, name, mtt->value);
+ break;
case INPUT_EVENT_KIND__MAX:
/* keep gcc happy */
break;