diff --git a/kcms/keyboard/CMakeLists.txt b/kcms/keyboard/CMakeLists.txt --- a/kcms/keyboard/CMakeLists.txt +++ b/kcms/keyboard/CMakeLists.txt @@ -1,15 +1,15 @@ add_definitions(-DTRANSLATION_DOMAIN=\"kcmkeyboard\") -option(HAVE_XINPUT "X11/XCB XInput" OFF) +option(HAVE_XINPUT "X11 XInput" OFF) option(HAVE_UDEV "UDev" OFF) option(NEW_GEOMETRY "Keyboard geometry preview" OFF) -if (X11_Xinput_FOUND AND XCB_XINPUT_FOUND) +if (X11_Xinput_FOUND) set(HAVE_XINPUT ON) elseif (UDEV_FOUND) set(HAVE_UDEV ON) else() - message(STATUS "X11/XCB XInput and UDev is not found, either is required to keep layouts with keyboard hotplugging") + message(STATUS "X11 XInput and UDev is not found, either is required to keep layouts with keyboard hotplugging") endif() diff --git a/kcms/keyboard/xinput_helper.cpp b/kcms/keyboard/xinput_helper.cpp --- a/kcms/keyboard/xinput_helper.cpp +++ b/kcms/keyboard/xinput_helper.cpp @@ -30,7 +30,18 @@ #ifdef HAVE_XINPUT #include -#include +#include +typedef struct xcb_input_device_presence_notify_event_t { + uint8_t response_type; + uint8_t pad0; + uint16_t sequence; + xcb_timestamp_t time; + uint8_t devchange; + uint8_t device_id; + uint16_t control; + uint8_t pad1[20]; +} xcb_input_device_presence_notify_event_t; +// FIXME: #include once xcb-xinput is stable #endif #include "x11_helper.h"