summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/xcb/qxcbwindow.cpp
Commit message (Collapse)AuthorAgeFilesLines
* xcb: another QXcbScreen null pointer checkShawn Rutledge2015-03-111-0/+2
| | | | | | | | | | In QXcbWindow::setParent(), the window may not have a screen, and in that case we cannot get the root window in this way. Task-number: QTBUG-44719 Change-Id: I719e5e2f8cad13b1460b4d9df6ffd6c4a48e0d37 Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
* Have XCB/Windows platform integration classes keep their own instance pointerSandro Mani2015-02-251-1/+1
| | | | | | | | | | | | Through the chain of code called by QPlatformIntegrationFactory::create, there are cases where QGuiApplicationPrivate::platform_integration is accessed (typically through QGuiApplicationPrivate::platformIntegration()) before the call to QPlatformIntegrationFactory::create has returned. Change-Id: I7805b72be5b56aed5cb8ce30cb908743c9b1f91b Task-number: QTBUG-44388 Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
* Merge remote-tracking branch 'origin/5.4' into 5.5Frederik Gladhorn2015-02-241-0/+12
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: examples/xml/htmlinfo/simpleexample.html examples/xml/rsslisting/rsslisting.cpp qmake/generators/win32/msbuild_objectmodel.cpp src/3rdparty/harfbuzz-ng/src/hb-private.hh src/corelib/global/qlogging.cpp src/corelib/io/qstorageinfo_unix.cpp src/corelib/thread/qwaitcondition_unix.cpp src/gui/kernel/qguiapplication.cpp src/plugins/platforms/linuxfb/qlinuxfbintegration.cpp src/testlib/doc/src/qt-webpages.qdoc tests/auto/other/qaccessibility/tst_qaccessibility.cpp Change-Id: Ib272ff0bc30a1a5d51275eb3cd2f201dc82c11ff
| * Merge remote-tracking branch 'origin/5.4.1' into 5.4Frederik Gladhorn2015-02-101-0/+12
| |\ | | | | | | | | | Change-Id: I9d668a655b548feab43e9d4b03e2437bdff76437
| | * Fix Qt over VNC with broken VisualInfoAllan Sandfeld Jensen2015-02-021-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It appears some VNC servers reports incorrect masks in their visuals. This patch recognizes this unlikely set of masks and interprets it as RGB16 which VNC expects. Task-number: QTBUG-44147 Change-Id: Ia374edcd5f0a5ce0188157ac1d328f888cfa260c Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com> Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
* | | xcb: QSystemTrayIcon: grab background pixmap for compositing only onceShawn Rutledge2015-02-121-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Followup to 2203d9d93e24e00d6e9bc9bda0e65a0c7f9923cc: clearRegion takes a little time, so doing grabWindow() too soon afterwards can result in grabbing a pixmap with undesired leftovers. And doing it every time we render the icon causes flicker. So, do clearRegion() ASAP when showing the icon, wait for it to happen, then grabWindow() only the first time we render, and reuse the resulting pixmap for all future calls to paintEvent(). (The downside is, if there is any corruption during the first grabWindow(), it's going to stay there as long as the app is running.) Task-number: QTBUG-35658 Change-Id: If881ab192dba43758dcbb0d080663ff42057fa4f Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
* | | Update copyright headersJani Heikkinen2015-02-111-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Qt copyrights are now in The Qt Company, so we could update the source code headers accordingly. In the same go we should also fix the links to point to qt.io. Outdated header.LGPL removed (use header.LGPL21 instead) Old header.LGPL3 renamed to header.LGPL3-COMM to match actual licensing combination. New header.LGPL-COMM taken in the use file which were using old header.LGPL3 (src/plugins/platforms/android/extract.cpp) Added new header.LGPL3 containing Commercial + LGPLv3 + GPLv2 license combination Change-Id: I6f49b819a8a20cc4f88b794a8f6726d975e8ffbe Reviewed-by: Matti Paaso <matti.paaso@theqtcompany.com>
* | | Merge remote-tracking branch 'origin/5.4' into devFrederik Gladhorn2015-02-101-0/+6
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/3rdparty/harfbuzz-ng/harfbuzz-ng.pro src/gui/image/qimage_conversions.cpp src/gui/opengl/qopenglextensions_p.h src/gui/text/qtextengine.cpp src/network/ssl/qsslsocket_openssl.cpp src/plugins/platforms/eglfs/qeglfshooks_stub.cpp src/plugins/platforms/eglfs/qeglfsscreen.cpp src/plugins/platforms/eglfs/qeglfswindow.cpp src/plugins/platforms/windows/qwindowsfontdatabase.cpp src/plugins/platforms/windows/qwindowsfontdatabase_ft.cpp src/plugins/platforms/windows/qwindowsnativeinterface.cpp src/plugins/platforms/windows/qwindowsscreen.cpp src/plugins/platforms/windows/qwindowswindow.cpp src/plugins/platforms/windows/qwindowswindow.h src/plugins/platforms/xcb/qxcbdrag.h src/widgets/itemviews/qabstractitemview.cpp src/widgets/kernel/qwidget.cpp src/widgets/util/qsystemtrayicon_p.h tests/auto/corelib/itemmodels/qsortfilterproxymodel/tst_qsortfilterproxymodel.cpp Thanks to Friedemann Kleint for resolving the qwindowsfontdatabase.cpp conflicts. Change-Id: I937232c30523d5121c195d947d92aec6f129b03e
| * | xcb: delay showing tray icon window until it is embeddedShawn Rutledge2015-02-051-0/+6
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Otherwise there is a race condition: when the tray implementation gets around to embedding the window, if it was already shown, it will be unmapped, embedded, and then remapped. Some tray implementations will resize the tray icon to 1 pixel wide in that case. We also never want to show a window that was intended for the tray in any other location, so it's better that it remain invisible until we are sure it is embedded. Task-number: QTBUG-31762 Task-number: QTBUG-35658 Task-number: QTBUG-32811 Change-Id: Id324b0bfded0f8258ff1686a223cb2c069827d42 Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
* | Handle gracefully the removal and re-attachment of all QScreensShawn Rutledge2015-02-071-12/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Don't crash; restore windows when all screens are removed and re-added. xcb: on configure notify, check for screen change: it may be that a window belonging to a screen which was removed has now gotten mapped to the new screen. On screen change, send a synthetic expose event, because the real expose events already happened. Task-number: QTBUG-38326 Task-number: QTBUG-32973 Task-number: QTBUG-42985 Change-Id: If334f55c248468ad3c95e7066bb14eca377d2050 Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
* | Remove todo note about QXcbWindow::format()Laszlo Agocs2015-02-051-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | It _is_ the actual format after create(). This is true at least since modularizing the GLX and EGL integration. See resolveFormat() in the integration plugins. This is important to clarify since other platform plugins usually return the input (requested) format as-is. We must therefore be careful with misleading notes as the situation is complicated enough already. Change-Id: I8e394680fa8fe3c80941a2a08fa873f831d6403c Reviewed-by: Andy Nichols <andy.nichols@theqtcompany.com>
* | QXcbWindow: use an accessor to get the screen instead of storing itSandro Mani2015-02-041-40/+44
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Applications which construct a window with one screen configuration and show the window later on after a screen configuration change crash because the QXcbWindow::m_screen still pointed to the screen present at the time of window construction. In QXcbWindow::handleConfigureNotifyEvent the m_screen should get updated with the new screen, but I didn't see that method called in the scenario outlined. Looking at the other platform backends, I however see that they take the screen directly from the QPlatformWindow instead of storing the instance, hence this patch which makes QXcbWindow do the same. Change-Id: I13759a5939315c3aac36ec6e2c25bd0a6d7b1c35 Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com> Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
* | Merge remote-tracking branch 'origin/5.4' into devFrederik Gladhorn2015-01-211-6/+35
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/global/global.pri src/corelib/global/qcompilerdetection.h src/corelib/global/qglobal.h src/corelib/tools/qdatetime.cpp src/plugins/platforms/xcb/qxcbscreen.h src/plugins/platforms/xcb/qxcbwindow.h src/widgets/dialogs/qcolordialog.cpp src/widgets/dialogs/qcolordialog_p.h tools/configure/configureapp.cpp Change-Id: Ie9d6e9df13e570da0a90a67745a0d05f46c532af
| * Fix constantly growing window bug with devicePixelRatioPaul Olav Tvete2015-01-161-6/+10
| | | | | | | | | | | | | | | | | | | | | | | | Rectangles need to be mapped differently depending on what they are used for. Expose events need to cover the entire geometry, so they must be rounded up, potentially increasing the size. If we use the same conversion for window geometries, it is possible to end up with a feedback loop if the window reacts to the new size. Task-number: QTBUG-43743 Change-Id: I7881cc77bf2148fed2ae743c4226617a61197434 Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
| * X11 devicePixelRatio screen mapping fixPaul Olav Tvete2015-01-121-2/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix screen detection and window geometry when screens have different displayPixelRatios. We must use the native coordinate system to figure out which screen a window belongs to. Also, when a window moves to a screen with a different devicePixelRatio, we must recalculate the Qt geometry. Task-number: QTBUG-43713 Change-Id: I93063e37354ff88f3c8a13320b76dfb272e43a9c Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
* | Fix build when using -egl and -no-xcb-xlibGiulio Camuffo2014-12-231-0/+2
| | | | | | | | | | Change-Id: I533f1d989b5f4b427ce572620e27c3870a64c2ae Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
* | Make GLX and EGL dynamic dependencies for xcbJørgen Lind2014-12-201-62/+12
|/ | | | | | | | | | | | [ChangeLog][QPA][Xcb] GLX and EGL code paths are now dynamically resolved, making it possible for one build of a plugin to use both code paths. Default is to use the GLX code path if available. This can be overwritten by specifying QT_XCB_GL_INTEGRATION=xcb_egl as an evnironment variable. Enable qt.xcb.glintegration.debug to get debug log output of what integration is used Change-Id: Ia9fa95fcca3d901b91dadb8c98a695fea0ae3b1e Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
* XCB: send leave event on grabJørgen Lind2014-11-261-16/+17
| | | | | | | | | | | | | | When a popup is opened it grabs the input, but the leave event to the other windows needs to be sent. Remove the popupEnterLeave test as it did not test any code. The Popup never gets any enter or leave events so it will succeed always succeed Task-number: QTBUG-36862 Change-Id: I625c616eeb74b5168af7b751485e2a9a53b76cd3 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com> Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* Make the -nograb and -dograb arguments actually work on xcbJørgen Lind2014-11-111-0/+6
| | | | | Change-Id: Idc725443e4abe27db3e530f08173897bfcbe1278 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
* xcb: Fix setting the alert state for a windowAlexander Volkov2014-10-291-6/+3
| | | | | | | | | | Send a _NET_WM_STATE client message to the root window instead of changing the window property. Task-number: QTBUG-41310 Change-Id: I864af0158ec55796bb3cbc123469709b2be54ec8 Reviewed-by: Martin Gräßlin <mgraesslin@kde.org> Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* XCB: Always set X window attributes in QXcbWindow::setWindowFlags().Friedemann Kleint2014-10-171-20/+31
| | | | | | | | | | | | | | QDockWidget and QToolBar set the Qt::BypassWindowManagerHint window flag when unplugging and clear it in the endDrag() methods. This does not have any effect since the attribute is not taken into account in QXcbWindow::setWindowFlags(). Change the method to always set the attributes, which should also make it possible to set/clear Qt::WindowTransparentForInput. Task-number: QTBUG-41189 Task-number: QTBUG-38964 Change-Id: Id9eddc642489d18f44c7597f8fc1a1df71971306 Reviewed-by: Andy Shaw <andy.shaw@digia.com> Reviewed-by: Gatis Paeglis <gatis.paeglis@digia.com>
* xcb: Fix detecting the fullscreen state from _NET_WM_STATE flagsAlexander Volkov2014-09-291-3/+3
| | | | | | | | A fullscreen window can have maximized flags being set so first check the NetWmStateFullScreen flag. Change-Id: Ia802abf3cfa4c784baa2d55088e3f53310f0362e Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* xcb: Fix logic for minimized stateAlexander Volkov2014-09-291-0/+4
| | | | | | | | | | | _NET_WM_STATE message can be received by a window in the minimized state. Don't change the window state in this case. Task-number: QTBUG-31117 Task-number: QTBUG-39376 Task-number: QTBUG-34430 Change-Id: Ic77a345e442891972b692803fab1e2f6aef30433 Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* Update license headers and add new license filesMatti Paaso2014-09-241-19/+11
| | | | | | | | | - Renamed LICENSE.LGPL to LICENSE.LGPLv21 - Added LICENSE.LGPLv3 - Removed LICENSE.GPL Change-Id: Iec3406e3eb3f133be549092015cefe33d259a3f2 Reviewed-by: Iikka Eklund <iikka.eklund@digia.com>
* devicePixelRatio support for XCBPaul Olav Tvete2014-08-191-39/+88
| | | | | | | | | | This adds support for the environment variable QT_DEVICE_PIXEL_RATIO for the xcb platform plugin. Task-number: QTBUG-38858 Change-Id: I7faca2f2e7dc5c601a82b3cc08456870b3e5602d Reviewed-by: Allan Sandfeld Jensen <allan.jensen@digia.com> Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
* Remove specific maemo/meego codepathsAllan Sandfeld Jensen2014-08-061-34/+2
| | | | | | | | | We no longer support the maemo/meego platform, so we can remove the specific code for that platform. Change-Id: Ia7f0730eba2d96794b97b7ca4753f63a2d7bc2a8 Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com> Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
* Avoid calling syncWindow with already destroyed platform windowsLaszlo Agocs2014-08-011-0/+13
| | | | | | | | | | | | | Issuing a metacall from swapBuffers is dangerous since the window may get destroyed by the time the slot is invoked. This patch changes it to use an event, which is more efficient anyway, that can be invalidated in case the QXcbWindow is destroy()'ed before the event is delivered. Change-Id: I44618ac1cb8b221aecce001ea39702164dcab6a5 Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com> Reviewed-by: Uli Schlachter <psychon@znc.in>
* Remove pointless debug outputAleix Pol2014-08-011-4/+1
| | | | | | | | | | Removes some debug output that indicates that we're dealing with a dock. It looks like somebody was testing some implementation more than useful output information. Change-Id: I04ebbc1f0f1d29ed2099bab9d9e9fc18c9bf0c86 Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com> Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
* Don't reset the window type on window showAleix Pol2014-07-291-2/+4
| | | | | | | | | | | | We were resetting the window type on show, this was breaking some deployments, since it used to be possible to set the xcb properties from the user application. This change requires the user to at least start using the QtPlatformHeaders before overriding the window properties with the values set there. Change-Id: Ic58919a42b6d532035c7ec6158a086b85666a22f Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* Add convenience function for checking screen changes to QPlatformWindow.Friedemann Kleint2014-07-071-8/+4
| | | | | | | | | | | | Add function returning the screen for a new geometry for geometry change events. This ensures that the checking is done in platform screen coordinates (which might differ from QScreen coordinates due to high-DPI changes) and also that no screen changes are emitted for child windows. Change-Id: I406750f59f006f834c386d09c0c85a804014924a Reviewed-by: Jørgen Lind <jorgen.lind@digia.com> Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* Merge "Merge remote-tracking branch 'origin/5.3' into dev" into refs/staging/devFrederik Gladhorn2014-07-041-0/+1
|\
| * Merge remote-tracking branch 'origin/5.3' into devFrederik Gladhorn2014-07-031-0/+1
| |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/gui/accessible/qaccessiblecache_mac.mm src/gui/accessible/qaccessiblecache_p.h src/plugins/platforms/cocoa/qcocoaaccessibilityelement.h src/plugins/platforms/cocoa/qcocoawindow.h src/plugins/platforms/cocoa/qcocoawindow.mm src/widgets/kernel/qwidget_qpa.cpp Manually moved change in qwidget_qpa.cpp to qwidget.cpp (cd07830e3b27da7e96a0a83f91ba08c168b45e62) Change-Id: Ia51f471f9b53de2f3b07d77ea89db9303ac8961d
| | * xcb: make sure to update window title when it is changedTasuku Suzuki2014-07-021-0/+1
| | | | | | | | | | | | | | | | | | | | | Task-number: QTBUG-33775 Change-Id: Ibe346c4304532d031bfa1c9b4d73cd02d1e5a64f Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com> Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* | | QImage support for RGB30 formatsAllan Sandfeld Jensen2014-07-041-10/+33
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | Adds basic support for 10-bit per color channel formats to QImage and the XCB plugin. This will make it possible to paint to and from these formats, but only at 8-bit per color channel accuracy. This also fixes Qt5 applications on X11 with native 30bit depth. [ChangeLog][QtGui][QImage] Added support for 10-bit per color channel image formats. Task-number: QTBUG-25998 Change-Id: I93ccd3c74bfbb0bd94b352476e5fe58a94119e1f Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
* | Merge remote-tracking branch 'origin/5.3' into devFrederik Gladhorn2014-07-011-4/+30
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: mkspecs/qnx-x86-qcc/qplatformdefs.h src/corelib/global/qglobal.h src/network/socket/qnativesocketengine_winrt.cpp src/plugins/platforms/android/androidjniaccessibility.cpp src/plugins/platforms/windows/qwindowswindow.cpp Manually adjusted: mkspecs/qnx-armle-v7-qcc/qplatformdefs.h to include 9ce697f2d54be6d94381c72af28dda79cbc027d4 Thanks goes to Sergio for the qnx mkspecs adjustments. Change-Id: I53b1fd6bc5bc884e5ee2c2b84975f58171a1cb8e
| * Fix alpha in no-opengl configuration on xcbLaszlo Agocs2014-06-061-4/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Like the EGL + xcb configuration, the -no-opengl is broken too when it comes to translucent windows: Requesting an alpha channel is futile since the xcb_create_window call always uses the root's depth and visual. This is now corrected by picking a 32-bit visual. This will make translucent windows and drag pixmaps appear correctly again. Task-number: QTBUG-35126 Change-Id: I00e7d6e08b5fcc055ef3ea6d822561740a1f5457 Reviewed-by: Gatis Paeglis <gatis.paeglis@digia.com>
* | Merge remote-tracking branch 'origin/stable' into devJ-P Nurmi2014-06-051-2/+23
|\| | | | | | | | | | | | | | | | | | | Conflicts: mkspecs/features/qt.prf src/plugins/platforms/xcb/qxcbwindow.h src/tools/qdoc/qdocindexfiles.cpp src/widgets/kernel/qwidget_qpa.cpp Change-Id: I214f57b03bc2ff86cf3b7dfe2966168af93a5a67
| * Improve the implementation of the _NET_WM_SYNC_REQUEST protocolMartin Gräßlin2014-05-271-2/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change improves the synced resizes of xcb windows and adds support for synced resizes of glx windows. The QXcbWindow keeps a better track on whether the window manager expects a sync and can be in one of three states: * no sync required * sync required, but configure notify event not yet received * sync required and configured By tracking this in the QXcbWindow itself the backing store can make use of this information and doesn't need an own heuristic to decide whether a sync is needed. Also this allows to add support for synced resizes of windows with an OpenGLSurface. This is accomplished by checking the sync state after swapping buffers. As the OpenGL context may be bound to a background thread the sync is done using a QueuedConnection to ensure that the sync happens in the thread which created the xcb window. So far this is only added for GLX. This significantly improves the resize experience of QQuickWindow and also the initial mapping with a composited window manager in case the compositor uses the sync protocol to determine whether the window is ready to get painted on screen. Change-Id: Ied0261873043d785dec652d2821fc3638292fa36 Reviewed-by: Uli Schlachter <psychon@znc.in> Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
* | Use QtPlatformHeaders to set platform specific functionalityJorgen Lind2014-05-091-0/+132
|/ | | | | | | | | | | This involves exposing a new function in the QPlatformNativeInterface which gets a public function for QGuiApplication Proof of concept is done through implementing _NET_WM_WINDOW_TYPE setters for xcb Change-Id: Ic9544e775fb71cc9b30273595ec41b1cdb1c9d64 Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* Merge remote-tracking branch 'origin/release' into stableFrederik Gladhorn2014-05-011-10/+10
|\ | | | | | | | | | | This merge adds the opengl rename. Change-Id: I84ea0b6abee9780ebb2cf3f64ab9e3fdf2acab3e
| * Use runtime detection of XInput 2.1 to disable legacy wheel eventsAllan Sandfeld Jensen2014-04-251-10/+10
| | | | | | | | | | | | | | | | | | | | Ensure we fall back to using wheel button events if xinput 2.1 scroll events are not available. Handles lack of xinput 2.1 support in the server or in the input devices drivers. Task-number: QTBUG-38169 Change-Id: Ie4ad9069f648d0ab02d8f9540ed01ad58fd9e9d8 Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* | Merge remote-tracking branch 'origin/release' into stableJani Heikkinen2014-04-231-0/+3
|\| | | | | | | Change-Id: Id13b4a3803664692f32f9d57549be8a0c4a08567
| * Reload lastScrollPosition on window enterAllan Sandfeld Jensen2014-04-151-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | We need the lastScrollPosition position to calculated scrolling deltas on scroll events. Since the position is tied to the device and might have changed while scroll events were send to other applications we need to reload the value when mouse focus reenters our application. Task-number: QTBUG-38274 Change-Id: Ic166648f8e7ae486288cbed339a057e3faa1ef2d Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com> Reviewed-by: Daniel Teske <daniel.teske@digia.com> Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* | XCB: fix that modal dialogs can go behind other process windowsJorgen Lind2014-04-161-33/+71
| | | | | | | | | | | | | | Task-number: QTBUG-35302 Change-Id: I1ad7a66e530710d5338a15057254360dae676451 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* | Handle parent is None from query_tree_reply in QxcbWindow::frameMarginsMartin Gräßlin2014-04-141-1/+1
|/ | | | | | | | | | None is a valid return value for parent in xcb_query_tree_reply_t. If that is used as the new parent the next call to xcb_query_tree_unchecked will fail with a BadWindow error. Change-Id: Iafe29b223ca65c86ecfd40fe51e67d4bd7abc1ce Reviewed-by: Jørgen Lind <jorgen.lind@digia.com> Reviewed-by: Uli Schlachter <psychon@znc.in>
* XCB: Only use the XFixes extension if availableUli Schlachter2014-04-091-1/+1
| | | | | | | | | | | | | | | | | | Commit 0d4918950e61f added a new place (QXcbWindow::setTransparentForMouseEvents()) where requests from the XFixes extension are generated. However, this wasn't checking if the extension is actually supported before using it. Fix this by turning QXcbWindow::setTransparentForMouseEvents() into a no-op if the XFixes extension isn't available. This means that the window in question won't be transparent for mouse events, but we cannot do much about that if the X server doesn't support the required extension. Task-number: QTBUG-38109 Change-Id: I2931481eb71bab990f2dcf0ec600b9e62d3d799c Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* Fix regression in minimized state handlingLaszlo Agocs2014-03-251-5/+5
| | | | | | | | | | | | WM_STATE and _NET_WM_STATE are not the same. c6e271da6d1d972ad73a97871baafe57578a69a9 introduces a severe regression in this respect, making applications on xcb not to follow window state changes properly. Task-number: QTBUG-37695 Change-Id: Ia058bc11d5aa988eab513939c9f755c2f77512ee Reviewed-by: Martin Klapetek <mklapetek@kde.org> Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* QXcbWindow - inline the atom functionsMartin Klapetek2014-03-151-8/+5
| | | | | Change-Id: I3a8f9efb7de21bf2301721edca49c9411c62eed0 Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
* Update QScreen::availableGeometry() on _NET_WORKAREA atom changesMartin Klapetek2014-03-151-0/+3
| | | | | | | | | | | | | | When the window manager sets new workarea using the _NET_WORKAREA xcb atom, QScreen::availableGeometry() does not react to that and returns an invalid available geometry. This patch reacts to that change and updates the QScreen property properly on xcb platform. Change-Id: I8f0b4a27bab0ce450fb7393f4d9a56f3ce9a4ea1 Reviewed-by: Uli Schlachter <psychon@znc.in> Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Jørgen Lind <jorgen.lind@digia.com> Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* Remove usage of QT_NO_SHAPEGatis Paeglis2014-03-071-7/+1
| | | | | | | | | | | | | First of all QT_NO_SHAPE was never set in configure script, which means that !contains(DEFINES, QT_NO_SHAPE):LIBS += -lxcb-shape always was true and we were linking to -lxcb-shape no matter what. Secondly, we are providing shape.c in qtbase/src/3rdparty/xcb/libxcb, so users always have an -qt-xcb option available to get this extension. Change-Id: I7d14a0ac5ca6e36fb9c053225916cae41028b532 Reviewed-by: Uli Schlachter <psychon@znc.in> Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>