pkgsrc/devel/kwayland/patches/patch-src_server_seat__interface.cpp
markd e081d3566f kwayland: update to 5.93.0
5.81.0
Bump required PlasmaWaylandProtocols
Fix DTD check errors and a typo
Add the activity management protocol client implementation

5.82.0
Add VRR to output device and management
Use new version-controlled enumerator deprecation warning macros
Add support for overscan
Bump plasma-wayland-protocols dependency to 1.2.1
Bump required PlasmaWaylandProtocols

5.83.0
Use protocol files from plasma-wayland-protocols
Update Plasma Wayland Protocols dependency to 1.3.0
Do not emit Surface::leave twice when an output is removed

5.85.0
Fix check for mmap failure

5.86.0
Implement set_frost in contrast protocol
Implement org_kde_plasma_window_management::send_to_output
Decouple activation feedback from plasma window management global
plasma-window-management: Support new activation concepts

5.88.0
Correct the eglQueryWaylandBufferWL_func prototype

5.90.0
Make linux/input.h a hard dependency

5.91.0
Ensure when unmapped is emitted, ::windows() will not contain unmapped window
Don't use hard-coded versions with targets and variables
Install pkg-config file
Deprecate PlasmaWindowModel::requestVirtualDesktop()
kwayland server has been moved to plasma kwayland-server since 5.73
src/client: wrap deprecated methods in deprecation macros

5.92.0
Check executables exist in PATH before passing them to QProcess

5.93.0
Install Client headers in a dirs hierarchy matching the C++ namespaces
We don't actually need Qt6WaylandCompositor
2022-04-25 05:26:49 +00:00

44 lines
1.3 KiB
C++

$NetBSD: patch-src_server_seat__interface.cpp,v 1.1 2022/04/25 05:26:49 markd Exp $
linux/input.h only for linux
--- src/server/seat_interface.cpp.orig 2022-04-02 10:04:14.000000000 +0000
+++ src/server/seat_interface.cpp
@@ -19,7 +19,9 @@
#define WL_SEAT_NAME_SINCE_VERSION 2
#endif
+#ifdef Q_OS_LINUX
#include <linux/input.h>
+#endif
#include <functional>
@@ -38,6 +40,10 @@ SeatInterface::Private::Private(SeatInte
{
}
+#ifndef Q_OS_LINUX
+enum mouse_button { BTN_LEFT, BTN_RIGHT, BTN_MIDDLE, BTN_TOUCH };
+#endif
+
#ifndef K_DOXYGEN
const struct wl_seat_interface SeatInterface::Private::s_interface = {getPointerCallback, getKeyboardCallback, getTouchCallback, releaseCallback};
#endif
@@ -753,6 +759,7 @@ namespace
static quint32 qtToWaylandButton(Qt::MouseButton button)
{
static const QHash<Qt::MouseButton, quint32> s_buttons({
+#ifdef BTN_LEFT
{Qt::LeftButton, BTN_LEFT},
{Qt::RightButton, BTN_RIGHT},
{Qt::MiddleButton, BTN_MIDDLE},
@@ -769,6 +776,7 @@ static quint32 qtToWaylandButton(Qt::Mou
{Qt::ExtraButton11, BTN_TASK + 6},
{Qt::ExtraButton12, BTN_TASK + 7},
{Qt::ExtraButton13, BTN_TASK + 8}
+#endif
// further mapping not possible, 0x120 is BTN_JOYSTICK
});
return s_buttons.value(button, 0);