From 1d8879f09367aeac9d43e9310e9871f2dd046aec Mon Sep 17 00:00:00 2001 From: Ilya Fedin Date: Mon, 11 Apr 2022 01:07:10 +0400 Subject: Client: Expose default input device's serial through integration Default input device is not so useful without serial for calls like xdg_toplevel_show_window_menu This is done in the same way as apptime/appusertime/gettimestamp in xcb's native interface. Pick-to: 6.4 Change-Id: I20e7dee19cf20e819a557e23c539066945cecb46 Reviewed-by: David Edmundson --- src/client/qwaylandnativeinterface.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src') diff --git a/src/client/qwaylandnativeinterface.cpp b/src/client/qwaylandnativeinterface.cpp index 2c9ba899..f8ae07aa 100644 --- a/src/client/qwaylandnativeinterface.cpp +++ b/src/client/qwaylandnativeinterface.cpp @@ -98,6 +98,8 @@ void *QWaylandNativeInterface::nativeResourceForIntegration(const QByteArray &re return touch->wl_touch(); return nullptr; } + if (lowerCaseResource == "serial") + return reinterpret_cast(quintptr(m_integration->display()->defaultInputDevice()->serial())); return nullptr; } -- cgit v1.2.1