summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel/qapplication_x11.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Fixed broken window surface flush when depth is 24 and bpp is not 32.Samuel Rødal2011-09-291-0/+6
| | | | | | | | | | | | Some X servers use a compact representation of 24 depth visuals. In that case we can't use the shared memory or XPutImage paths, as Qt's RGB32 does not match the internal memory layout. Also fixed QPixmap::fromImage() to work in this case to prevent the red and blue channels from being swapped. Task-number: QTBUG-21754 Reviewed-by: Alberto Mardegan
* Add a QApplication::queryKeyboardModifiers() method.David Faure2011-08-171-0/+15
| | | | | | | | | | QApplication::keyboardModifiers returns the keyboard modifiers from the last keypress event in this process, as documented. However there are use cases for querying keyboard modifiers as they currently are, see QTBUG-11243. Merge-request: 585 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>
* Merge remote-tracking branch 'qt/4.8'Jyri Tahtela2011-05-181-3/+0
|\ | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: doc/src/examples/wheel.qdoc src/gui/util/qflickgesture.cpp src/gui/util/qflickgesture_p.h src/gui/util/qscroller.cpp src/gui/util/qscroller.h src/gui/util/qscroller_p.h src/gui/util/qscrollerproperties.cpp src/gui/util/qscrollerproperties.h tests/auto/qscroller/tst_qscroller.cpp
| * Revert all QScroller and QFlickGesture related code.Robert Griebl2011-05-161-3/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commits 0274e68767cce6440515a68d6af868725d5577a4 2770b1277744bb676e96e4ae8c89acd645ec895d 02e1f4e83dc8e3c4ab957095167b3d34c51ba3c1 fdf3be5b6b5db75833e0a7e9a90445ddd794fe4d d1f9a534da288884f443a975f428b0cfe0a7b29b 205d607c3387d074fb87f8deb77a8f515ae2e189 32d200da9cc7a4dfb3f302f22ef5718a286845c9 3e0df49f978933b1e4e6b48c695bf813ec9a2828 82bbc1c1611bde33680d22a1a3c6449e51d7b0b9 b78ffe51f9a4c4ac705e435d45fffe39864c032d fe438d7d828021d7f86301af36fe8dff2768532a df30d58de183d13c649ef7e0fbb8e2b3658e0862 fa845566b3733bc06454b71e33b1ff405ba32280 4f9a318d639c4e7e09e56751d31608fb39d472af 4810b587a65d81f8f90646efd09cadeb1276a756 7bad867382ad6c84155ffcfbb361709a8e8184ab 64ec011c6132496eb9555c1d09e7fd4ddf472837 81492e56aba5b5761500543665012a85d6835513 b668857b3749b39c3a61e0a25e750740b74df552 78a7a02b3b85435bc28eb23e9210522467171e42 Reviewed-By: Ralf Engels
* | Update licenseheader text in source files for qt4.8Jyri Tahtela2011-05-131-17/+17
|/ | | | | | | Updated version of LGPL and FDL licenseheaders. Apply release phase licenseheaders for all source files. Reviewed-by: Trust Me
* Track compositingManagerRunning changesJacopo De Simoi2011-03-311-0/+9
| | | | | | | | | | | | | | | | Use XFixes extension to track changes to the compositing manager in such a way that QX11Info::isCompositingManagerRunning() returns a valid result even if compositing has changed after the creation of the QApplication Many thanks to Fredrikh Hoglund for suggesting the correct approach Task-number: QTBUG-6044 Merge-request: 1133 Reviewed-by: Denis Dzyubenko <denis.dzyubenko@nokia.com>
* Take Xft.hintstyle by default to match the behavior of GTK+Jiang Jiang2011-03-251-0/+4
| | | | | | | | For Qt apps running in GNOME, we use the GTK+ settings by default (instead of fontconfig settings). Task-number: QTBUG-13800 Reviewed-by: Samuel
* Merge branch earth-team/master into earth-stagingJoão Abecasis2011-02-161-14/+17
|\ | | | | | | | | Conflicts: doc/src/development/qmake-manual.qdoc
| * Fixed mapFromGlobal in some window managers on X11Denis Dzyubenko2011-02-081-1/+16
| | | | | | | | | | | | | | | | | | | | | | | | The previous mapFromGlobal optimization in cdd776a91e65bf5c30cea1bab9823134a3f797d0 broke behavior in some window managers like metacity when resizing by dragging the top-left corner. Most likely it is a bad behaviour of the window manager (according to ICCCM 4.1.5 we should get a ConfigureNotify event with x and y in root coordinates if you consider this is a "movement" of a window). Reviewed-by: Olivier Goffart
| * Removed obsolete code that was incorrectly handling ConfigureNotifyDenis Dzyubenko2011-02-081-13/+1
| | | | | | | | | | | | | | | | | | | | | | The code in question was calling XSync and then processing ConfigureNotify requests, but only using the width/height information from the event, while ignoring the x,y properties. The code was consuming synthetic ConfigureNotify with x,y in root coordinate system that we are supposed to receive from the window manager, which broke mapFromGlobal/mapToGlobal behavior (after cdd776a91e65bf5c30cea1bab9823134a3f797d0) Reviewed-by: Olivier Goffart
* | Merge remote-tracking branch 'origin/4.7' into qt-master-from-4.7Olivier Goffart2011-02-101-3/+14
|\ \ | |/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: doc/src/development/qmake-manual.qdoc mkspecs/symbian-gcce/qmake.conf qmake/project.cpp src/corelib/global/qnamespace.qdoc src/declarative/graphicsitems/qdeclarativetext.cpp src/gui/text/qtextdocumentlayout.cpp src/gui/text/qtextdocumentlayout_p.h tests/auto/declarative/qdeclarativetext/tst_qdeclarativetext.cpp tests/auto/networkselftest/networkselftest.pro tests/auto/qscriptengine/tst_qscriptengine.cpp tools/designer/src/components/signalsloteditor/signalslot_utils.cpp tools/designer/src/components/signalsloteditor/signalsloteditorwindow.cpp tools/qdoc3/test/qt-build-docs.qdocconf tools/qdoc3/test/qt-html-templates.qdocconf tools/qdoc3/test/qt-html-templates_zh_CN.qdocconf tools/qdoc3/test/qt.qdocconf tools/qdoc3/test/qt_ja_JP.qdocconf tools/qdoc3/test/qt_zh_CN.qdocconf
| * Check that _POSIX_THREAD_SAFE_FUNCTIONS is larger than zero.Thiago Macieira2011-02-081-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | POSIX allows this symbol to be defined to -1 to indicate that the interfaces aren't present. On FreeBSD 8, it's defined to -1, but the functions are present (supposedly, they don't work -- just stubs). Guessing that OpenBSD is the same. Also removing the QT_NO_THREAD, since Qt can't be built without threading support. It's only used by our bootstrapped tools, which in turn use QCoreApplication only (no QApplication). Reviewed-By: Bradley T. Hughes
| * Use an increasing size for the getpwuid_r buffer.Thiago Macieira2011-02-081-1/+12
| | | | | | | | Reviewed-by: Bradley T. Hughes
| * Make sure we use at least 1024 bytes when calling getpwuid_r.Thiago Macieira2011-02-081-1/+1
| | | | | | | | | | | | | | On some systems, sysconf may return -1 to indicate that there's no such limit (limitless), so don't create a buffer of size -1. Reviewed-by: Bradley T. Hughes
* | Merge remote branch 'origin/4.7' into qt-master-from-4.7Olivier Goffart2011-01-171-1/+1
|\ \ | |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: examples/webkit/imageanalyzer/imageanalyzer.h examples/webkit/imageanalyzer/mainwindow.h mkspecs/unsupported/qws/linux-x86-openkode-g++/qplatformdefs.h src/corelib/io/qfsfileengine_iterator_unix.cpp src/corelib/io/qfsfileengine_iterator_win.cpp src/corelib/kernel/qcoreapplication.cpp src/network/access/qnetworkaccessdatabackend.cpp src/plugins/bearer/connman/qconnmanservice_linux.cpp src/plugins/platforms/openvglite/qwindowsurface_vglite.h src/s60installs/bwins/QtCoreu.def src/s60installs/eabi/QtCoreu.def src/s60installs/s60installs.pro tools/assistant/tools/assistant/helpviewer_qwv.h tools/qdoc3/test/qt-html-templates.qdocconf
| * Update copyright year to 2011.Jason McDonald2011-01-101-1/+1
| | | | | | | | Reviewed-by: Trust Me
* | Resolve XRRSizes() from libxrandr for QScroller's DPI calculation.Robert Griebl2010-12-151-0/+3
| | | | | | | | Reviewed-by: Denis Dzyubenko
* | Merge remote branch 'origin/4.7' into qt-master-from-4.7Olivier Goffart2010-11-051-0/+24
|\ \ | |/ | | | | | | | | Conflicts: mkspecs/features/symbian/symbian_building.prf src/network/access/qhttpnetworkconnectionchannel.cpp
| * Cleanup Meego Compositor detectionHarald Fernengel2010-11-021-27/+17
| | | | | | | | | | | | | | Make the code friendlier and rename the enum value to DE_MEEGO_COMPOSITOR Reviewed-by: Robert Griebl
| * Added Maemo 6 to the X11 desktopEnvironment listDominik Holland2010-11-021-0/+34
| | | | | | | | DE_MAEMO6 is set when the rootwindow is MCompositor
* | Merge branch 4.7 into qt-master-from-4.7Qt Continuous Integration System2010-10-251-1/+1
|\ \ | |/
| * Fixed many spelling errors.Rohan McGovern2010-10-251-1/+1
| |
* | Merge remote branch 'origin/4.7' into qt-master-from-4.7Thiago Macieira2010-09-221-1/+0
|\ \ | |/ | | | | | | | | Conflicts: src/gui/painting/qtextureglyphcache_p.h src/opengl/gl2paintengineex/qtextureglyphcache_gl.cpp
| * remove extra includesRitt Konstantin2010-09-211-1/+0
| |
* | Merge remote branch 'origin/4.7' into qt-master-from-4.7Thiago Macieira2010-09-211-0/+28
|\ \ | |/ | | | | | | | | | | | | Conflicts: src/corelib/kernel/qobject.h src/declarative/graphicsitems/qdeclarativeflickable.cpp src/declarative/graphicsitems/qdeclarativeflickable_p_p.h src/declarative/util/qdeclarativelistmodel.cpp
| * Added private API to install an x11EventFilterHarald Fernengel2010-09-101-0/+28
| | | | | | | | | | | | | | | | Some libs need to intercept X11 events without actually being able to subclass QApplication, so add a private API to allow setting event filter functions. Reviewed By: Robert Griebl
* | Merge remote branch 'origin/4.7' into qt-master-from-4.7Olivier Goffart2010-09-101-0/+7
|\ \ | |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: bin/syncqt demos/declarative/snake/content/snake.js demos/declarative/snake/snake.qml doc/src/development/qmake-manual.qdoc src/corelib/plugin/plugin.pri src/gui/kernel/qapplication_win.cpp src/gui/kernel/qdesktopwidget_win.cpp src/gui/painting/qdrawhelper.cpp tests/auto/qdir/tst_qdir.cpp tools/qdoc3/test/assistant.qdocconf tools/qdoc3/test/designer.qdocconf tools/qdoc3/test/linguist.qdocconf
| * Fixed hiding a window on X11 before it was shown.Denis Dzyubenko2010-09-071-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | On X11 show() just issues a request to show a window, so if someone tries to call hide() before the window was successfully mapped to the screen by the window manager it will not work (on most window managers unfortunately). So instead, when hide() is called we internally mark the window as "no need to show anymore" and then if we still get MapNotify event, we will hide the window right away. Reviewed-by: Markus Goetz Reviewed-by: Bradley T. Hughes
* | Merge remote branch 'origin/4.7' into qt-master-from-4.7Thiago Macieira2010-07-151-1/+1
|\ \ | |/ | | | | | | Conflicts: src/gui/kernel/qapplication.h
| * Fix compilation when configured with -no-xrenderGunnar Sletta2010-06-251-1/+1
| | | | | | | | Reviewed-by: Eskil
* | Add an application attribute to control XInitThreads().Trond Kjernåsen2010-07-021-0/+3
| | | | | | | | | | | | | | In order to make Xlib thread-safe XInitThreads() needs to be the first Xlib call issued. This attribute controls this behavior. Having Xlib thread-safe will most likely incur some overhead, which is why this is not done by default.
* | Merge remote branch 'origin/master'Olivier Goffart2010-06-151-1/+1
|\ \ | |/ | | | | | | Conflicts: src/gui/painting/qpainter.cpp
| * Merge remote branch 'origin/4.6' into qt-4.7-from-4.6Olivier Goffart2010-06-081-1/+1
| |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/3rdparty/webkit/VERSION src/3rdparty/webkit/WebCore/ChangeLog src/3rdparty/webkit/WebKit/qt/Api/qwebpage.cpp src/3rdparty/webkit/WebKit/qt/ChangeLog src/gui/painting/qpainter.cpp src/gui/painting/qtextureglyphcache.cpp src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp src/opengl/gl2paintengineex/qtextureglyphcache_gl_p.h src/s60installs/bwins/QtGuiu.def src/s60installs/eabi/QtCoreu.def src/s60installs/eabi/QtGuiu.def src/s60installs/eabi/QtNetworku.def src/s60installs/eabi/QtOpenVGu.def tests/auto/qfontmetrics/tst_qfontmetrics.cpp tools/linguist/lupdate/main.cpp
| | * Added reference counting to QWidgetBackingStoreGareth Stockwell2010-06-021-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On Symbian, the top-level widget's backing store must be destroyed when it is no longer required, in order to conserve memory. The criteria for destroying the backing store is when neither the TLW nor any of its native descendents (which share the backing store) are visible. In order to implement this requirement, a count must be kept of the number of native widgets which are using the TLW's backing store. This patch provides the mechanism for maintaining this count, and for destroying the backing store when the count is decremented to zero. No calls to either the increment nor decrement functions are made, however, by this code included in this patch; this code will be added to only the Symbian backend by a subsequent patch. Task-number: QTBUG-8697 Reviewed-by: Bjørn Erik Nilsen Reviewed-by: Jason Barron
* | | Qt now really unloads plugins and libraries when exiting an appThierry Bastian2010-06-041-16/+12
|/ / | | | | | | | | | | | | | | It also means that when creating a QPluginLoader or a QLibrary for a dynamic lib already loaded, isLoaded will return true immediately after the creation of the instance of QPluginLoader or QLibrary. Reviewed-By: Jan-Arve Saether
* | Do not move keyboard focus to invisible windows on X11.Denis Dzyubenko2010-03-241-5/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | When QWidget::activateWindow() is called we check if the window was already mapped and just do not do anything if it wasn't. We used to try to active it by giving it keyboard focus, but that always fails because it isn't allowed to call XSetInputFocus on invisible windows, and the error message was swalled by Qt in the error handler. So now we just don't bother even trying if we know the call will fail. Task-number: QTBUG-4042 Reviewed-by: Benjamin Poulain Reviewed-by: Bradley T. Hughes
* | Revert "Revert "Make QWidget::activateWindow() NET window manager aware.""Denis Dzyubenko2010-03-241-0/+2
| | | | | | | | This reverts commit 555175f9d9e5633b8fcfd6e6f6a11c84faa9946e.
* | Revert "Make QWidget::activateWindow() NET window manager aware."Morten Johan Sørvig2010-03-241-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 6390248b11b3596d8c946c232e9b0d832dc42941, which caused the following regressions: TESTFUNCTION_FAIL qshortcut::ambiguousItems (pulse_linux-g++) TESTFUNCTION_FAIL qshortcut::ambiguousRotation (pulse_linux-g++) TESTFUNCTION_FAIL qshortcut::disabledItems (pulse_linux-g++) TESTFUNCTION_FAIL qshortcut::keypressConsumption (pulse_linux-g++) TESTFUNCTION_FAIL qshortcut::number (pulse_linux-g++) TESTFUNCTION_FAIL qshortcut::text (pulse_linux-g++) TESTFUNCTION_FAIL qshortcut::unicodeCompare (pulse_linux-g++)
* | Add a new WA_X11DoNotAcceptFocus attribute for top-level widgets (part 2).Robert Griebl2010-03-221-0/+2
| | | | | | | | | | | | | | Forgot the documentation and ignoring WM_TAKE_FOCUS messages for modal windows in part 1 (9da453e5579ebb6fb0361e4df4cfa7107e560b23) Reviewed-by: bhughes
* | Make QWidget::activateWindow() NET window manager aware.Robert Griebl2010-03-221-0/+2
| | | | | | | | | | | | | | Use the _NET_ACTIVE_WINDOW atom if the current window manager supports it - otherwise fall back to XSetInputFocus() Reviewed-by: bhughes
* | Improve keyboard layout detection on X11Bradley T. Hughes2010-03-151-9/+54
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When the keyboard configuration includes multiple layouts in separate groups, the _XKB_RULES_NAME property lists the layouts separated by a comma. Previously we did not handle this. We query the current keyboard group on startup and monitor XkbStateNotify events for group changes. The existing infrastructre from QKeyMapper deals with sending the KeyboardLayoutChange event to all toplevel windows already. This change includes a bit of refactoring to put the XKB detection and initialization in qapplication_x11.cpp and XKB opcode, eventbase, and errorbase into qt_x11_p.h (like with the other extensions). Task-number: QTBUG-3631 Reviewed-by: denis
* | Merge remote branch 'origin/4.6' into qt-4.7-from-4.6Rohan McGovern2010-03-061-4/+14
|\ \ | |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: configure.exe examples/multimedia/audioinput/audioinput.cpp src/corelib/io/qfsfileengine.cpp src/gui/egl/qegl_wince.cpp src/gui/egl/qeglproperties.cpp src/gui/egl/qeglproperties_p.h src/gui/embedded/directfb.pri src/gui/kernel/qapplication_win.cpp src/gui/painting/qdrawutil.cpp src/opengl/qgl_p.h src/sql/drivers/odbc/qsql_odbc.cpp src/sql/drivers/odbc/qsql_odbc.h tests/auto/auto.pro tests/auto/qgl/tst_qgl.cpp translations/assistant_adp_ru.ts
| * Make tablet detection work with new wacom driversThomas Zander2010-03-041-2/+7
| | | | | | | | | | | | | | | | | | | | | | wacom driver fixed a bug in assigning atom names where it messed up the device names. Their solution apparently renamed the atoms The type names used now are "STYLUS", "CURSOR", "ERASER", "PAD" and "TOUCH" for each respective device. This change detects those as our tablet input devices. Reviewed-by: Benjamin Poulain <benjamin.poulain@nokia.com> Task-number: QTBUG-8599
| * Fix build break in qapplication_x11.cpp.Adrian Constantin2010-03-031-0/+5
| | | | | | | | Reviewed-by: TrustMe
| * Allow platform specific values for the double click radius.Raino Priha2010-03-021-2/+2
| | | | | | | | | | Task-number: QT-2883 Reviewed-by: Volker Hilsheimer
* | Fix seg-fault when no X11 desktop environment is presentTom Cooksey2010-02-241-23/+53
| | | | | | | | Reviewed-By: ossi
* | clean up x11 desktop detectionOswald Buddenhagen2010-02-221-86/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | KDE_FULL_SESSION is reliable since kde 2.x or so. DESKTOP_SESSION is not reliable, unless one uses a new gnome. GNOME_DESKTOP_SESSION_ID was temporarily unreliable. the two together should be reliable. copy the xfce4 detection from the xdg-open tool. assumed to be reliable. remove the window manager hacks, as they are redundand with the asssumedly reliable detection methods above. Reviewed-by: jbache
* | Merge remote branch 'origin/4.6' into qt-master-from-4.6Thiago Macieira2010-02-121-0/+8
|\ \ | |/
| * Fixed compilation with QT_NO_WHEELEVENTDenis Dzyubenko2010-02-101-0/+8
| | | | | | | | Reviewed-by: Prasanth
* | Merge branch '4.6'Thiago Macieira2010-01-131-1/+1
|\ \ | |/ | | | | | | | | | | | | | | | | | | Conflicts: bin/syncqt doc/src/deployment/deployment.qdoc src/corelib/io/qfsfileengine_win.cpp src/corelib/xml/qxmlstream.cpp src/opengl/gl2paintengineex/qpaintengineex_opengl2_p.h tools/assistant/tools/assistant/centralwidget.cpp tools/linguist/lupdate/main.cpp