summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/xcb
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/platforms/xcb')
-rw-r--r--src/plugins/platforms/xcb/README10
-rw-r--r--src/plugins/platforms/xcb/qxcbconnection_xi2.cpp21
2 files changed, 11 insertions, 20 deletions
diff --git a/src/plugins/platforms/xcb/README b/src/plugins/platforms/xcb/README
index 15cf4cf241..5efc9b7f99 100644
--- a/src/plugins/platforms/xcb/README
+++ b/src/plugins/platforms/xcb/README
@@ -21,3 +21,13 @@ REDUCING RUNTIME DEPENDENCIES
The '-qt-xcb' configure option can be used to get rid of most xcb- dependencies. Only libxcb will
still be linked dynamically, since it will be most likely be pulled in via other dependencies anyway.
This should allow for binaries that are portable across most modern Linux distributions.
+
+PACKAGE VERSION REQUIREMENTS
+
+When using touch input via XInput 2.2 or higher, there is a potential issue on systems that ship with
+a libXi older than 1.7.4. This is because XIAllowTouchEvents can deadlock with libXi 1.7.3 and earlier.
+When touch events are never received, this is not an issue, so plain mouse/keyboard systems are not affected.
+See http://lists.x.org/archives/xorg-devel/2014-July/043059.html for details on the libXi patch.
+Qt versions before 5.8 attempted to recognize this scenario based on the pkg-config package version and skip
+the call. This has been removed starting from 5.8 since relying on pkg-config package versions is unsafe given
+that Qt must also support systems with limited or incomplete pkg-config setups.
diff --git a/src/plugins/platforms/xcb/qxcbconnection_xi2.cpp b/src/plugins/platforms/xcb/qxcbconnection_xi2.cpp
index 1147fc82b2..93f8db92bf 100644
--- a/src/plugins/platforms/xcb/qxcbconnection_xi2.cpp
+++ b/src/plugins/platforms/xcb/qxcbconnection_xi2.cpp
@@ -697,26 +697,7 @@ void QXcbConnection::xi2ProcessTouch(void *xiDevEvent, QXcbWindow *platformWindo
if (m_xiGrab) {
// XIAllowTouchEvents deadlocks with libXi < 1.7.4 (this has nothing to do with the XI2 versions like 2.2)
// http://lists.x.org/archives/xorg-devel/2014-July/043059.html
-#ifndef XCB_USE_XINPUT2
- static bool allowTouchWarningShown = false;
- if (!allowTouchWarningShown) {
- allowTouchWarningShown = true;
- qWarning("Skipping XIAllowTouchEvents() because it was not possible to detect libXi version at build time."
- " Minimum libXi version required is 1.7.4."
- " Expect issues with touch behavior.");
- }
-#elif QT_LIBRARY_VERSION(xinput2) < QT_VERSION_CHECK(1, 7, 4)
- static bool allowTouchWarningShown = false;
- if (!allowTouchWarningShown) {
- allowTouchWarningShown = true;
- qWarning("Skipping XIAllowTouchEvents() due to not having libXi >= 1.7.4."
- " libXi version at build time was %d.%d.%d."
- " Expect issues with touch behavior.",
- QT_LIBRARY_VERSION_MAJOR(xinput2),
- QT_LIBRARY_VERSION_MINOR(xinput2),
- QT_LIBRARY_VERSION_PATCH(xinput2));
- }
-#else
+#ifdef XCB_USE_XINPUT2
XIAllowTouchEvents(static_cast<Display *>(m_xlib_display), xiDeviceEvent->deviceid,
xiDeviceEvent->detail, xiDeviceEvent->event, XIAcceptTouch);
#endif