From 29787ec29cfa579e5bbf896dee093931a9f1385f Mon Sep 17 00:00:00 2001 From: Allan Sandfeld Jensen Date: Tue, 19 Aug 2014 14:45:45 +0200 Subject: Detect wrongly labelled wheel buttons A mouse device with both missing labels and a wrongly placed label on the mouse wheel buttons have been spotted. This patch makes the XInput2 code even more lenient to better match legacy systems that always assumed button 4 and 5 are mapped that way. Task-number: QTBUG-40806 Change-Id: I7cc52f3d9c54e15e6f3ddcc2bdeb1bb8e0ac9eca Reviewed-by: Shawn Rutledge --- src/plugins/platforms/xcb/qxcbconnection_xi2.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/plugins/platforms/xcb') diff --git a/src/plugins/platforms/xcb/qxcbconnection_xi2.cpp b/src/plugins/platforms/xcb/qxcbconnection_xi2.cpp index e21db89a20..4986e85728 100644 --- a/src/plugins/platforms/xcb/qxcbconnection_xi2.cpp +++ b/src/plugins/platforms/xcb/qxcbconnection_xi2.cpp @@ -164,7 +164,10 @@ void QXcbConnection::xi2SetupDevices() if (bci->num_buttons >= 5) { Atom label4 = bci->labels[3]; Atom label5 = bci->labels[4]; - if ((!label4 || qatom(label4) == QXcbAtom::ButtonWheelUp) && (!label5 || qatom(label5) == QXcbAtom::ButtonWheelDown)) + // Some drivers have no labels on the wheel buttons, some have no label on just one and some have no label on + // button 4 and the wrong one on button 5. So we just check that they are not labelled with unrelated buttons. + if ((!label4 || qatom(label4) == QXcbAtom::ButtonWheelUp || qatom(label4) == QXcbAtom::ButtonWheelDown) && + (!label5 || qatom(label5) == QXcbAtom::ButtonWheelUp || qatom(label5) == QXcbAtom::ButtonWheelDown)) scrollingDevice.legacyOrientations |= Qt::Vertical; } if (bci->num_buttons >= 7) { -- cgit v1.2.3 From 07c34fcc8a721ffe989eb8882b75ecb95600516c Mon Sep 17 00:00:00 2001 From: Dyami Caliri Date: Wed, 18 Jun 2014 22:20:05 -0700 Subject: xcb: use keyboard event source window to determine auto-repeat value The xcb auto-repeat checking code checks for queued events on the target (focused) window. This breaks down if you have a native child widget, and QKeyEvent::autoRepeat is never true. Task-number: QTBUG-21500 Change-Id: Ia979edfa8a3afce07a3e1cbaa778541ffb9ce5dc Reviewed-by: Gatis Paeglis --- src/plugins/platforms/xcb/qxcbconnection.cpp | 2 +- src/plugins/platforms/xcb/qxcbkeyboard.cpp | 27 ++++++++++++++------------- src/plugins/platforms/xcb/qxcbkeyboard.h | 6 +++--- 3 files changed, 18 insertions(+), 17 deletions(-) (limited to 'src/plugins/platforms/xcb') diff --git a/src/plugins/platforms/xcb/qxcbconnection.cpp b/src/plugins/platforms/xcb/qxcbconnection.cpp index 7f23c84cb9..5345d930a8 100644 --- a/src/plugins/platforms/xcb/qxcbconnection.cpp +++ b/src/plugins/platforms/xcb/qxcbconnection.cpp @@ -466,7 +466,7 @@ break; if (QXcbWindowEventListener *eventListener = windowEventListenerFromId(e->event)) { \ handled = eventListener->handleGenericEvent(event, &result); \ if (!handled) \ - m_keyboard->handler(m_focusWindow ? m_focusWindow : eventListener, e); \ + m_keyboard->handler(e); \ } \ } \ break; diff --git a/src/plugins/platforms/xcb/qxcbkeyboard.cpp b/src/plugins/platforms/xcb/qxcbkeyboard.cpp index 4c84b19f82..af75b650d1 100644 --- a/src/plugins/platforms/xcb/qxcbkeyboard.cpp +++ b/src/plugins/platforms/xcb/qxcbkeyboard.cpp @@ -1295,7 +1295,7 @@ private: bool m_release; }; -void QXcbKeyboard::handleKeyEvent(QWindow *window, QEvent::Type type, xcb_keycode_t code, +void QXcbKeyboard::handleKeyEvent(xcb_window_t sourceWindow, QEvent::Type type, xcb_keycode_t code, quint16 state, xcb_timestamp_t time) { Q_XCB_NOOP(connection()); @@ -1303,6 +1303,13 @@ void QXcbKeyboard::handleKeyEvent(QWindow *window, QEvent::Type type, xcb_keycod if (!m_config) return; + QXcbWindow *source = connection()->platformWindowFromId(sourceWindow); + QXcbWindow *targetWindow = connection()->focusWindow() ? connection()->focusWindow() : source; + if (!targetWindow || !source) + return; + if (type == QEvent::KeyPress) + targetWindow->updateNetWmUserTime(time); + // It is crucial the order of xkb_state_key_get_one_sym & xkb_state_update_key operations is not reversed! xcb_keysym_t sym = xkb_state_key_get_one_sym(xkb_state, code); @@ -1343,7 +1350,7 @@ void QXcbKeyboard::handleKeyEvent(QWindow *window, QEvent::Type type, xcb_keycod } } else { // look ahead for auto-repeat - KeyChecker checker(((QXcbWindow *)window->handle())->xcb_window(), code, time); + KeyChecker checker(source->xcb_window(), code, time); xcb_generic_event_t *event = connection()->checkEvent(checker); if (event) { isAutoRepeat = true; @@ -1359,6 +1366,7 @@ void QXcbKeyboard::handleKeyEvent(QWindow *window, QEvent::Type type, xcb_keycod filtered = inputContext->filterEvent(&event); } + QWindow *window = targetWindow->window(); if (!filtered) { if (type == QEvent::KeyPress && qtcode == Qt::Key_Menu) { const QPoint globalPos = window->screen()->handle()->cursor()->pos(); @@ -1401,21 +1409,14 @@ QString QXcbKeyboard::lookupString(struct xkb_state *state, xcb_keycode_t code) return QString::fromUtf8(chars); } -void QXcbKeyboard::handleKeyPressEvent(QXcbWindowEventListener *eventListener, const xcb_key_press_event_t *event) +void QXcbKeyboard::handleKeyPressEvent(const xcb_key_press_event_t *event) { - QXcbWindow *window = eventListener->toWindow(); - if (!window) - return; - window->updateNetWmUserTime(event->time); - handleKeyEvent(window->window(), QEvent::KeyPress, event->detail, event->state, event->time); + handleKeyEvent(event->event, QEvent::KeyPress, event->detail, event->state, event->time); } -void QXcbKeyboard::handleKeyReleaseEvent(QXcbWindowEventListener *eventListener, const xcb_key_release_event_t *event) +void QXcbKeyboard::handleKeyReleaseEvent(const xcb_key_release_event_t *event) { - QXcbWindow *window = eventListener->toWindow(); - if (!window) - return; - handleKeyEvent(window->window(), QEvent::KeyRelease, event->detail, event->state, event->time); + handleKeyEvent(event->event, QEvent::KeyRelease, event->detail, event->state, event->time); } void QXcbKeyboard::handleMappingNotifyEvent(const void *event) diff --git a/src/plugins/platforms/xcb/qxcbkeyboard.h b/src/plugins/platforms/xcb/qxcbkeyboard.h index 11b7429aca..e816d3c003 100644 --- a/src/plugins/platforms/xcb/qxcbkeyboard.h +++ b/src/plugins/platforms/xcb/qxcbkeyboard.h @@ -64,8 +64,8 @@ public: ~QXcbKeyboard(); - void handleKeyPressEvent(QXcbWindowEventListener *eventListener, const xcb_key_press_event_t *event); - void handleKeyReleaseEvent(QXcbWindowEventListener *eventListener, const xcb_key_release_event_t *event); + void handleKeyPressEvent(const xcb_key_press_event_t *event); + void handleKeyReleaseEvent(const xcb_key_release_event_t *event); void handleMappingNotifyEvent(const void *event); Qt::KeyboardModifiers translateModifiers(int s) const; @@ -83,7 +83,7 @@ public: #endif protected: - void handleKeyEvent(QWindow *window, QEvent::Type type, xcb_keycode_t code, quint16 state, xcb_timestamp_t time); + void handleKeyEvent(xcb_window_t sourceWindow, QEvent::Type type, xcb_keycode_t code, quint16 state, xcb_timestamp_t time); void resolveMaskConflicts(); QString lookupString(struct xkb_state *state, xcb_keycode_t code) const; -- cgit v1.2.3 From 4a6772a587c8fe86f3f674a1d1164ad6659fbfca Mon Sep 17 00:00:00 2001 From: Pekka Vuorela Date: Thu, 21 Aug 2014 14:52:45 +0300 Subject: Fix handling QT_IM_MODULE=none Was added with 19a39a4 to allow no input context to be created. Broken by commit 24c10b0. Especially if compose input context didn't get compiled, the first input context found was loaded. Also made Xcb integration use compose plugin by default. Change-Id: I992eaa8b383320e4ab725bb7b79f561f4f841458 Reviewed-by: Gatis Paeglis --- src/plugins/platforms/xcb/qxcbconnection.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/plugins/platforms/xcb') diff --git a/src/plugins/platforms/xcb/qxcbconnection.cpp b/src/plugins/platforms/xcb/qxcbconnection.cpp index 5345d930a8..f100f2d2e9 100644 --- a/src/plugins/platforms/xcb/qxcbconnection.cpp +++ b/src/plugins/platforms/xcb/qxcbconnection.cpp @@ -384,6 +384,9 @@ QXcbConnection::QXcbConnection(QXcbNativeInterface *nativeInterface, bool canGra qunsetenv("DESKTOP_STARTUP_ID"); sync(); + + if (qEnvironmentVariableIsEmpty("QT_IM_MODULE")) + qputenv("QT_IM_MODULE", QByteArray("compose")); } QXcbConnection::~QXcbConnection() -- cgit v1.2.3 From f1bce3bc17ebb99b1512b07499988538465c78a2 Mon Sep 17 00:00:00 2001 From: Allan Sandfeld Jensen Date: Thu, 21 Aug 2014 15:33:09 +0200 Subject: Avoid crash if querying device that has gone away A device removed very fast after being inserted might disappear while we are still seting it up. We must therefore check if we indeed still get a matching device Task-number: QTBUG-40820 Change-Id: I4372fb1932264e5799f37cea0d016795e28ebed6 Reviewed-by: Shawn Rutledge --- src/plugins/platforms/xcb/qxcbconnection_xi2.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/plugins/platforms/xcb') diff --git a/src/plugins/platforms/xcb/qxcbconnection_xi2.cpp b/src/plugins/platforms/xcb/qxcbconnection_xi2.cpp index 4986e85728..b38f9d42a9 100644 --- a/src/plugins/platforms/xcb/qxcbconnection_xi2.cpp +++ b/src/plugins/platforms/xcb/qxcbconnection_xi2.cpp @@ -331,10 +331,12 @@ XInput2DeviceData *QXcbConnection::deviceForId(int id) { XInput2DeviceData *dev = m_touchDevices[id]; if (!dev) { - int unused = 0; + int nrDevices = 0; QTouchDevice::Capabilities caps = 0; dev = new XInput2DeviceData; - dev->xiDeviceInfo = XIQueryDevice(static_cast(m_xlib_display), id, &unused); + dev->xiDeviceInfo = XIQueryDevice(static_cast(m_xlib_display), id, &nrDevices); + if (nrDevices <= 0) + return 0; int type = -1; int maxTouchPoints = 1; bool hasRelativeCoords = false; -- cgit v1.2.3 From 41826cfbae4569255c78ea5ade2a4b7ed9a2dfe1 Mon Sep 17 00:00:00 2001 From: Shawn Rutledge Date: Thu, 28 Aug 2014 11:53:06 +0200 Subject: QGLXContext survives screen removal The screen pointer is usually only used to get the Display, which normally doesn't change anyway. Task-number: QTBUG-39996 Change-Id: Ie35f02fc9330647897a9f081afb8c9ce550eed2a Reviewed-by: Laszlo Agocs --- src/plugins/platforms/xcb/qglxintegration.cpp | 61 ++++++++++++++++----------- src/plugins/platforms/xcb/qglxintegration.h | 2 +- 2 files changed, 37 insertions(+), 26 deletions(-) (limited to 'src/plugins/platforms/xcb') diff --git a/src/plugins/platforms/xcb/qglxintegration.cpp b/src/plugins/platforms/xcb/qglxintegration.cpp index 9a56455940..67235e0ef1 100644 --- a/src/plugins/platforms/xcb/qglxintegration.cpp +++ b/src/plugins/platforms/xcb/qglxintegration.cpp @@ -162,7 +162,7 @@ static void updateFormatFromContext(QSurfaceFormat &format) QGLXContext::QGLXContext(QXcbScreen *screen, const QSurfaceFormat &format, QPlatformOpenGLContext *share) : QPlatformOpenGLContext() - , m_screen(screen) + , m_display(DISPLAY_FROM_XCB(screen)) , m_context(0) , m_shareContext(0) , m_format(format) @@ -186,7 +186,7 @@ QGLXContext::QGLXContext(QXcbScreen *screen, const QSurfaceFormat &format, QPlat glXCreateContextAttribsARBProc glXCreateContextAttribsARB = 0; glXCreateContextAttribsARB = (glXCreateContextAttribsARBProc) glXGetProcAddress((const GLubyte*)"glXCreateContextAttribsARB"); - QList glxExt = QByteArray(glXQueryExtensionsString(DISPLAY_FROM_XCB(m_screen), m_screen->screenNumber())).split(' '); + QList glxExt = QByteArray(glXQueryExtensionsString(m_display, screen->screenNumber())).split(' '); bool supportsProfiles = glxExt.contains("GLX_ARB_create_context_profile"); // Use glXCreateContextAttribsARB if available @@ -255,10 +255,10 @@ QGLXContext::QGLXContext(QXcbScreen *screen, const QSurfaceFormat &format, QPlat contextAttributes << None; - m_context = glXCreateContextAttribsARB(DISPLAY_FROM_XCB(screen), config, m_shareContext, true, contextAttributes.data()); + m_context = glXCreateContextAttribsARB(m_display, config, m_shareContext, true, contextAttributes.data()); if (!m_context && m_shareContext) { // re-try without a shared glx context - m_context = glXCreateContextAttribsARB(DISPLAY_FROM_XCB(screen), config, 0, true, contextAttributes.data()); + m_context = glXCreateContextAttribsARB(m_display, config, 0, true, contextAttributes.data()); if (m_context) m_shareContext = 0; } @@ -271,10 +271,10 @@ QGLXContext::QGLXContext(QXcbScreen *screen, const QSurfaceFormat &format, QPlat if (m_format.renderableType() == QSurfaceFormat::OpenGLES) return; - m_context = glXCreateNewContext(DISPLAY_FROM_XCB(screen), config, GLX_RGBA_TYPE, m_shareContext, true); + m_context = glXCreateNewContext(m_display, config, GLX_RGBA_TYPE, m_shareContext, true); if (!m_context && m_shareContext) { // re-try without a shared glx context - m_context = glXCreateNewContext(DISPLAY_FROM_XCB(screen), config, GLX_RGBA_TYPE, 0, true); + m_context = glXCreateNewContext(m_display, config, GLX_RGBA_TYPE, 0, true); if (m_context) m_shareContext = 0; } @@ -292,14 +292,14 @@ QGLXContext::QGLXContext(QXcbScreen *screen, const QSurfaceFormat &format, QPlat return; // Note that m_format gets updated with the used surface format - visualInfo = qglx_findVisualInfo(DISPLAY_FROM_XCB(screen), screen->screenNumber(), &m_format); + visualInfo = qglx_findVisualInfo(m_display, screen->screenNumber(), &m_format); if (!visualInfo) qFatal("Could not initialize GLX"); - m_context = glXCreateContext(DISPLAY_FROM_XCB(screen), visualInfo, m_shareContext, true); + m_context = glXCreateContext(m_display, visualInfo, m_shareContext, true); if (!m_context && m_shareContext) { // re-try without a shared glx context m_shareContext = 0; - m_context = glXCreateContext(DISPLAY_FROM_XCB(screen), visualInfo, 0, true); + m_context = glXCreateContext(m_display, visualInfo, Q_NULLPTR, true); } // Create a temporary window so that we can make the new context current @@ -309,20 +309,31 @@ QGLXContext::QGLXContext(QXcbScreen *screen, const QSurfaceFormat &format, QPlat // Query the OpenGL version and profile if (m_context && window) { - glXMakeCurrent(DISPLAY_FROM_XCB(screen), window, m_context); + glXMakeCurrent(m_display, window, m_context); updateFormatFromContext(m_format); // Make our context non-current - glXMakeCurrent(DISPLAY_FROM_XCB(screen), 0, 0); + glXMakeCurrent(m_display, 0, 0); } // Destroy our temporary window - XDestroyWindow(DISPLAY_FROM_XCB(screen), window); + XDestroyWindow(m_display, window); } QGLXContext::~QGLXContext() { - glXDestroyContext(DISPLAY_FROM_XCB(m_screen), m_context); + glXDestroyContext(m_display, m_context); +} + +static QXcbScreen *screenForPlatformSurface(QPlatformSurface *surface) +{ + QSurface::SurfaceClass surfaceClass = surface->surface()->surfaceClass(); + if (surfaceClass == QSurface::Window) { + return static_cast(static_cast(surface)->screen()); + } else if (surfaceClass == QSurface::Offscreen) { + return static_cast(static_cast(surface)->screen()); + } + return Q_NULLPTR; } bool QGLXContext::makeCurrent(QPlatformSurface *surface) @@ -330,24 +341,24 @@ bool QGLXContext::makeCurrent(QPlatformSurface *surface) bool success = false; Q_ASSERT(surface->surface()->supportsOpenGL()); - Display *dpy = DISPLAY_FROM_XCB(m_screen); GLXDrawable glxDrawable = 0; QSurface::SurfaceClass surfaceClass = surface->surface()->surfaceClass(); if (surfaceClass == QSurface::Window) { m_isPBufferCurrent = false; QXcbWindow *window = static_cast(surface); glxDrawable = window->xcb_window(); - success = glXMakeCurrent(dpy, glxDrawable, m_context); + success = glXMakeCurrent(m_display, glxDrawable, m_context); } else if (surfaceClass == QSurface::Offscreen) { m_isPBufferCurrent = true; QGLXPbuffer *pbuffer = static_cast(surface); glxDrawable = pbuffer->pbuffer(); - success = glXMakeContextCurrent(dpy, glxDrawable, glxDrawable, m_context); + success = glXMakeContextCurrent(m_display, glxDrawable, glxDrawable, m_context); } if (success) { int interval = surface->format().swapInterval(); - if (interval >= 0 && m_swapInterval != interval) { + QXcbScreen *screen = screenForPlatformSurface(surface); + if (interval >= 0 && m_swapInterval != interval && screen) { m_swapInterval = interval; typedef void (*qt_glXSwapIntervalEXT)(Display *, GLXDrawable, int); typedef void (*qt_glXSwapIntervalMESA)(unsigned int); @@ -356,15 +367,15 @@ bool QGLXContext::makeCurrent(QPlatformSurface *surface) static bool resolved = false; if (!resolved) { resolved = true; - QList glxExt = QByteArray(glXQueryExtensionsString(dpy, - m_screen->screenNumber())).split(' '); + QList glxExt = QByteArray(glXQueryExtensionsString(m_display, + screen->screenNumber())).split(' '); if (glxExt.contains("GLX_EXT_swap_control")) glXSwapIntervalEXT = (qt_glXSwapIntervalEXT) getProcAddress("glXSwapIntervalEXT"); if (glxExt.contains("GLX_MESA_swap_control")) glXSwapIntervalMESA = (qt_glXSwapIntervalMESA) getProcAddress("glXSwapIntervalMESA"); } if (glXSwapIntervalEXT) - glXSwapIntervalEXT(dpy, glxDrawable, interval); + glXSwapIntervalEXT(m_display, glxDrawable, interval); else if (glXSwapIntervalMESA) glXSwapIntervalMESA(interval); } @@ -376,9 +387,9 @@ bool QGLXContext::makeCurrent(QPlatformSurface *surface) void QGLXContext::doneCurrent() { if (m_isPBufferCurrent) - glXMakeContextCurrent(DISPLAY_FROM_XCB(m_screen), 0, 0, 0); + glXMakeContextCurrent(m_display, 0, 0, 0); else - glXMakeCurrent(DISPLAY_FROM_XCB(m_screen), 0, 0); + glXMakeCurrent(m_display, 0, 0); m_isPBufferCurrent = false; } @@ -389,7 +400,7 @@ void QGLXContext::swapBuffers(QPlatformSurface *surface) glxDrawable = static_cast(surface)->pbuffer(); else glxDrawable = static_cast(surface)->xcb_window(); - glXSwapBuffers(DISPLAY_FROM_XCB(m_screen), glxDrawable); + glXSwapBuffers(m_display, glxDrawable); if (surface->surface()->surfaceClass() == QSurface::Window) { QXcbWindow *platformWindow = static_cast(surface); @@ -397,7 +408,7 @@ void QGLXContext::swapBuffers(QPlatformSurface *surface) // use QueuedConnection to sync the window from the platformWindow's thread // as QXcbWindow is no QObject, a wrapper slot in QXcbConnection is used. if (platformWindow->needsSync()) - QMetaObject::invokeMethod(m_screen->connection(), "syncWindow", Qt::QueuedConnection, Q_ARG(QXcbWindow*, platformWindow)); + QMetaObject::invokeMethod(screenForPlatformSurface(surface)->connection(), "syncWindow", Qt::QueuedConnection, Q_ARG(QXcbWindow*, platformWindow)); } } @@ -410,7 +421,7 @@ void (*QGLXContext::getProcAddress(const QByteArray &procName)) () if (resolved && !glXGetProcAddressARB) return 0; if (!glXGetProcAddressARB) { - QList glxExt = QByteArray(glXGetClientString(DISPLAY_FROM_XCB(m_screen), GLX_EXTENSIONS)).split(' '); + QList glxExt = QByteArray(glXGetClientString(m_display, GLX_EXTENSIONS)).split(' '); if (glxExt.contains("GLX_ARB_get_proc_address")) { #if defined(Q_OS_LINUX) || defined(Q_OS_BSD4) void *handle = dlopen(NULL, RTLD_LAZY); diff --git a/src/plugins/platforms/xcb/qglxintegration.h b/src/plugins/platforms/xcb/qglxintegration.h index 00bba94ab3..560dd6ab67 100644 --- a/src/plugins/platforms/xcb/qglxintegration.h +++ b/src/plugins/platforms/xcb/qglxintegration.h @@ -76,7 +76,7 @@ public: static void queryDummyContext(); private: - QXcbScreen *m_screen; + Display *m_display; GLXContext m_context; GLXContext m_shareContext; QSurfaceFormat m_format; -- cgit v1.2.3 From 4b6d87372561c960a3e42989db8c0bdb02f1df4a Mon Sep 17 00:00:00 2001 From: Boris Savelev Date: Thu, 4 Sep 2014 14:50:40 +0400 Subject: Add QMAKE_CFLAGS_XCB to xcb Add QMAKE_CFLAGS_XCB to xcb-static, needed for successfully building with -qt-xcb. Add QMAKE_CFLAGS because some code gets built with the C compiler. Also, this fixes a compile error when xcb include is not in system include path. Task-number: QTBUG-41129 Change-Id: I842ebe391a7a857e234becc451c33601fce9b07a Reviewed-by: Shawn Rutledge --- src/plugins/platforms/xcb/xcb-plugin.pro | 1 + src/plugins/platforms/xcb/xcb-static/xcb-static.pro | 3 +++ 2 files changed, 4 insertions(+) (limited to 'src/plugins/platforms/xcb') diff --git a/src/plugins/platforms/xcb/xcb-plugin.pro b/src/plugins/platforms/xcb/xcb-plugin.pro index 4d76e4d449..874d42c36c 100644 --- a/src/plugins/platforms/xcb/xcb-plugin.pro +++ b/src/plugins/platforms/xcb/xcb-plugin.pro @@ -105,6 +105,7 @@ contains(QT_CONFIG, opengl) { DEFINES += $$QMAKE_DEFINES_XCB LIBS += $$QMAKE_LIBS_XCB QMAKE_CXXFLAGS += $$QMAKE_CFLAGS_XCB +QMAKE_CFLAGS += $$QMAKE_CFLAGS_XCB CONFIG += qpa/genericunixfontdatabase diff --git a/src/plugins/platforms/xcb/xcb-static/xcb-static.pro b/src/plugins/platforms/xcb/xcb-static/xcb-static.pro index dfdcb2e83a..d0fe282b14 100644 --- a/src/plugins/platforms/xcb/xcb-static/xcb-static.pro +++ b/src/plugins/platforms/xcb/xcb-static/xcb-static.pro @@ -10,6 +10,9 @@ XCB_DIR = ../../../../3rdparty/xcb INCLUDEPATH += $$XCB_DIR/include $$XCB_DIR/include/xcb $$XCB_DIR/sysinclude +QMAKE_CXXFLAGS += $$QMAKE_CFLAGS_XCB +QMAKE_CFLAGS += $$QMAKE_CFLAGS_XCB + # ignore compiler warnings in 3rdparty code QMAKE_CFLAGS_STATIC_LIB+=-w -- cgit v1.2.3