summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel
Commit message (Collapse)AuthorAgeFilesLines
* Make it possible to use QSocketNotifier in Lighthouse pluginsJørgen Lind2011-07-272-4/+18
| | | | | | | | | | | | | The idea is that now the plugin can register the event dispatcher in its constructor, so it can freely use QSocketNotifier or what not. If the plugin choses not to do so, then the createFunction will be called at a later point. Change-Id: I75fb2ee4180d9619ac94e75fbcf1efd7a2deecbc Reviewed-on: http://codereview.qt.nokia.com/2287 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* QWindow: Do not call setters for window state, type etc in creation.Friedemann Kleint2011-07-262-51/+18
| | | | | | | | | | | | | | Remove the need to do housekeeping and comparison of window types, etc in the platform window setters. They can safely assume the flags have really changed and something (potentially recreating the window) has to be done. createPlatformWindow() must then query all parameters from QWindow and apply them. Change-Id: I497060ba46a955cad1fa3cbb5eb91438a420b80e Reviewed-on: http://codereview.qt.nokia.com/2198 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Get the eglfs plugin compiling.Samuel Rødal2011-07-265-1/+58
| | | | | | | Change-Id: I5addb1a2593a670d559b9fbf9183f52af410895b Reviewed-on: http://codereview.qt.nokia.com/2176 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Fix MSVC compiler warning.Friedemann Kleint2011-07-261-1/+2
| | | | | | | | | class/struct mismatch. Change-Id: Ifaecc4ba4baeceb41fffba84678466faf48469bc Reviewed-on: http://codereview.qt.nokia.com/2156 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Lighthouse: Provide default plugin.Friedemann Kleint2011-07-251-4/+21
| | | | | | | | | Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com> Change-Id: I13e78c499f77ac6ad034e61488fc6ef00e2e2be8 Reviewed-on: http://codereview.qt.nokia.com/2124 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Compile fix.Friedemann Kleint2011-07-251-2/+5
| | | | | | | Change-Id: Iab8abc6ebd580f8bafc08b250244e72907c253f4 Reviewed-on: http://codereview.qt.nokia.com/2122 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Compile fix.Samuel Rødal2011-07-251-0/+212
| | | | | | | | | Added missing qscreen.cpp. Change-Id: Id79a6a12aca0758fdb1a168d63969940111f03dd Reviewed-on: http://codereview.qt.nokia.com/2119 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Add drag and drop events to QWindowSystemInterface.Laszlo Agocs2011-07-254-0/+65
| | | | | | | | | | | For non-desktop platforms these are better suited and are more QPA style than relying purely on QDragManager/QSimpleDrag/sending drag events directly to the windows. Change-Id: Id466830cf83427b3d86925602086a858e8f713e5 Reviewed-on: http://codereview.qt.nokia.com/2084 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Support non-desktop platforms better with QDragManager.Laszlo Agocs2011-07-252-0/+21
| | | | | | | | | | | | | | By default QDragManager brings in a number of "desktopisms" (e.g. that a drag is always controlled by mouse events, can be cancelled with some key press, etc.), these assumptions are not necessarily suitable for all QPA platforms. Therefore there has to be a way to disable this built-in event handling, and let the QPlaformDrag decide how the drag is controlled and when it ends. Change-Id: Ie9fa2df7ba1e30dd1c6e2cff406490e36be73c4f Reviewed-on: http://codereview.qt.nokia.com/2085 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Fix for not calling QPlatformCursor's pointerEvent.Laszlo Agocs2011-07-251-0/+9
| | | | | | | | | | The code to pass mouse events to platform cursors is there in 4.8, however it went missing in refactor. This patch restores it. Change-Id: I7873c892c1ae907fc084d3f00f7d4e5a6293ba4d Reviewed-on: http://codereview.qt.nokia.com/2083 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Added workable QScreen API on top of QPlatformScreen.Samuel Rødal2011-07-2515-69/+379
| | | | | | | | | | | | | | | | | | | | | QPlatformIntegration::screens() no longer has to be implemented, implementations should call QPlatformIntegration::screenAdded() for each screen instead. This is for being able to support adding screens at run-time later on, by connecting it to a signal in QGuiApplication. The QGuiGLContext API has changed a bit, by not sending in all the parameters in the constructor but instead having a create() function. The createPlatformGLContext() factory in QPlatformIntegration takes a QGuiGLContext * instead of a QSurfaceFormat and a share context, similar to how the window and backing store factory functions work. The XCB plugin has experimental support for connecting to multiple X displays simultaneously, creating one or more QScreen for each. Change-Id: I248a22a4fd3481280710110272c04a30a8021e8f Reviewed-on: http://codereview.qt.nokia.com/2103 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Rename QPixmapData to QPlatformPixmap.Samuel Rødal2011-07-192-5/+5
| | | | | | | | | Makes the API symmetric with the other Lighthouse APIs. Change-Id: I8a399f3c968ea35d4624711b31f2ac5bb94b7893 Reviewed-on: http://codereview.qt.nokia.com/1735 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Get rid of some obsolete functions in QImage / QPixmap / QPixmapData.Samuel Rødal2011-07-181-1/+1
| | | | | | | | Change-Id: I0d2412c9196475b926a17de9fcc3281f6625fae0 Reviewed-on: http://codereview.qt.nokia.com/1733 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com> Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Use PlatformNativeInterface to obtain backingStore's dcOlli Werwolff2011-07-122-0/+9
| | | | | | Change-Id: I6ec2fc0b8e7696fdfe4468920228df2d21c933fd Reviewed-on: http://codereview.qt.nokia.com/1501 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Use PlatformNativeInterface to obtain handlesOlli Werwolff2011-07-071-1/+1
| | | | | | | Change-Id: I8cdf3d5477e72e89bcde46ccb6670320bf4dd797 Reviewed-on: http://codereview.qt.nokia.com/1270 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Merge remote branch 'gerrit/master' into refactorLars Knoll2011-07-063-77/+169
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: config.tests/unix/opengldesktop/opengldesktop.cpp examples/itemviews/interview/interview.pro examples/mainwindows/mainwindow/mainwindow.pro examples/openvg/README examples/richtext/textedit/textedit.pro examples/tools/undo/undo.pro src/corelib/global/qglobal.h src/corelib/kernel/qcoreapplication.h src/corelib/kernel/qcoreevent.h src/corelib/kernel/qmetatype.h src/gui/kernel/qevent.cpp src/gui/kernel/qevent.h src/gui/painting/qpaintengine_raster.cpp src/gui/painting/qpaintengine_raster_p.h src/gui/text/qfontdatabase.cpp src/opengl/qgl.h src/openvg/qpaintengine_vg.cpp src/plugins/platforms/wayland/qwaylandwindow.cpp tests/auto/qmainwindow/qmainwindow.pro Change-Id: I6bfb586740a68379bb99f4612ec993393a5f3234
| * Add QScreenOrientationChangeEvent and rotation support to wayland clientLasse Holmstedt2011-07-043-0/+133
| | | | | | | | | | | | | | | | | | | | | | Qt Compositor propagates screen orientation changes to wayland, which are then picked up by the wayland client. The wayland client then sends a QScreenOrientationChangeEvent to QApplication, which can handle the orientation change. Change-Id: Ieb2225e52b7e3c318648f2cb21dab7937f301505 Reviewed-on: http://codereview.qt.nokia.com/1063 Reviewed-by: Matthias Ettrich
| * make QHoverEvent inherit from QInputEventLars Knoll2011-06-303-7/+9
| | | | | | | | | | | | | | | | | | | | QHoverEvent is an input event and as such should also contain the current keyboard modifiers. Change-Id: Ic403a8511eb991a9c6b5132908af1d5900869361 Reviewed-on: http://codereview.qt.nokia.com/937 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Paul Olav Tvete <paul.tvete@nokia.com>
| * Use floating point coordinates in eventsLars Knoll2011-06-273-75/+34
| | | | | | | | | | | | | | | | | | | | Use FP coordinates in Mouse, Wheel and Hover events. Change-Id: I8b43ca257620b4653ae5d6b6122c516384db1e48 Reviewed-on: http://codereview.qt.nokia.com/766 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Paul Olav Tvete <paul.tvete@nokia.com>
| * Fix event delevery orderOlivier Goffart2011-06-271-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Some functions (such as QObject::moveToThread) did not keep the event ordered by priority. And because qUpperBound is used to add events, that mean new events would not be inserted in order. Task-number: QTBUG19637 Change-Id: I38eb9addb1cdd45b8566e000361ac6e5f1f2c2b8 Reviewed-on: http://codereview.qt.nokia.com/733 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com> Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com>
| * Support -qtnamespace and -qtlibinfix againLiang Qi2011-06-201-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | This fix is for qtbase libraries with -qtnamespace and -qtlibinfix options in configure. Task-number: QTBUG-19964 Change-Id: I2f2ff1748f2c1c2b20d5f73b6be36f68a7a26cef Reviewed-on: http://codereview.qt.nokia.com/505 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com> Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
| * Initialize member variable.Gunnar Sletta2011-06-141-1/+2
| | | | | | | | | | | | | | Change-Id: Ica42c77614fa4fa9ae7692e00d3fc796219aacdc Reviewed-on: http://codereview.qt.nokia.com/466 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
| * Fix infinite recursion when changing geometry on MacGabriel de Dietrich2011-05-261-7/+5
| | | | | | | | | | | | | | | | | | | | | | | | Some complex widgets might get a negatively sized rectangle when calling QWidgetPrivate:setGeometry_sys_helper(), triggering a infinite recursion. Normalizing the rectangle size before checking for size change is enough to break this infinite recursion. Task-number: QTBUG-17333 Change-Id: I4682c3088ea53fb9f28f746c8264f573b5284825 Reviewed-on: http://codereview.qt.nokia.com/156 Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com>
| * Compile. Morten Sorvig2011-05-251-13/+0
| | | | | | | | | | Change 0748751c brought in an extra copy of this function.
* | Start porting the Mac menu system to QPA.Morten Sorvig2011-07-061-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Global changes: qglobal.h: remove code that sets Q_WS_MAC and Q_MAC_USE_COCOA - this is dead code now. Add qt_widget_helpers_mac_p.h/mm which will contain helper functions needed for widgets on Qt 5. Menu-related changes: Set AA_DontUseNativeMenuBar before creating the platform plugin. Change Q_WS_MAC to Q_OS_MAC in the menu code. Remove Q_MAC_USE_COCOA defines and Carbon code paths. Move some qt_mac helper functions only used by the menu system to qmenu_mac.mm. #ifdef out some code paths that require further porting. Native menus are now disabled by default but can be enabled by the QPA plugins that want them by clearing AA_DontUseNativeMenuBar. Since we at compile time don't know which plugin will be loaded the Mac menu code is always included when building on OS X. (The above is currently only relevant for the Cocoa plugin.)
* | Get declarative and wayland EGL backend working for Qt compositor.Samuel Rødal2011-06-233-1/+11
| |
* | Add QWindowSystemInterface::windowSystemEventsQueued()Morten Sorvig2011-06-233-1/+7
| | | | | | | | | | | | This removes the last use of QWindowSystemInterfacePrivate from outside QtGui, so we can make that class non-exported again.
* | Refactor window system event dispatching.Morten Sorvig2011-06-232-0/+38
| | | | | | | | | | | | | | | | | | | | Add QWindowSystemInterface::sendWindowSystemEvents, which contains the canonical "empty and send queued window system events" implementation. Make the Cocoa, QPA, and GLIB dispatchers use the new implementation. Cocoa now no longer inherits from QPA.
* | Reintroduce QWindow::SurfaceTypeMorten Sorvig2011-06-223-0/+19
| | | | | | | | | | | | | | On Cocoa it makes sense to distinguish between the two window types. Reviewed-by: Samuel
* | Compile.Friedemann Kleint2011-06-221-0/+1
| |
* | Make xcb work again after event dispatcher changes.Morten Johan Sorvig2011-06-221-1/+0
| | | | | | | | | | | | The platform plugin/event dispatcher creation order has now been reversed and the event dispatcher cannot be accessed during plugin construciton.
* | add QInputMethodQueryEventLars Knoll2011-06-222-0/+63
| | | | | | | | | | | | | | QInputMethodQueryEvent will replace the old inputMethodHints() and inputMethodQuery() APIs in QWidget. It has the advantage that it works nicely with any kind of QObject.
* | add a platform interface for input method supportLars Knoll2011-06-225-0/+158
| | | | | | | | | | | | | | | | add QPlatformInputContext to help supporting complex text input. Communication with the focus objects/widgets will happen slightly different then before, through events instead of methods one can query on QWidget.
* | Add lighthouse event dispatcher API.Morten Sorvig2011-06-2212-1874/+56
| | | | | | | | | | | | | | | | | | | | Platform plugin creation is now moved forward in order to have a platform plugin instance at event dispatcher creation time. Plugins are now responsible for implementing PlatformIntegration::createEventDispatcher and returning an QAbstractEventDispatcher subclass.
* | Made QExposeEvent public and added exposeEvent() in QWindow.Samuel Rødal2011-06-225-12/+44
| | | | | | | | This is needed for applications that use QBackingStore directly.
* | OpenGL API refactor.Samuel Rødal2011-06-2113-203/+161
| | | | | | | | | | | | Rename QGuiGLFormat to QSurfaceFormat, and make QWindow sub-class of QSurface and QPlatformWindow sub-class of QPlatformSurface, instead of having QPlatformGLSurface accessor in QWindow.
* | Rename QWindowSurface -> QBackingStore and split into platform / public.Samuel Rødal2011-06-215-25/+8
| | | | | | | | Also get rid of GL window surface and related classes.
* | Compile fixes.Samuel Rødal2011-06-211-0/+1
| |
* | Add a platform API for QClipboard::ownsMode()Lars Knoll2011-06-203-4/+9
| | | | | | | | Simply forward ownsMode() to the QPlatformClipboard.
* | Make glx wayland backends working.Laszlo Agocs2011-06-201-0/+1
| |
* | Compile.Friedemann Kleint2011-06-141-0/+1
| |
* | Added frameMargins() API and support in XCB plugin.Samuel Rødal2011-06-104-0/+19
| |
* | Compile Windows.Friedemann Kleint2011-06-102-2/+2
| |
* | Actually add QEventDispatcherMac.Morten Sorvig2011-06-102-0/+1368
| |
* | QWindowContext / QWindowFormat refactor.Samuel Rødal2011-06-1015-362/+430
| | | | | | | | | | | | | | | | | | | | | | | | | | To enable having a single GL context used for multiple drawables we need to de-couple the context class a bit more from the window class in the plugin API. Now contexts are created stand-alone based on a GL format and a share context, and when calling makeCurrent() a desired surface is specified. This maps well to GLX, EGL, Cocoa, AGL, and WGL, which all support this use case. QWindowContext is renamed to QGuiGLContext, and QWindowFormat is renamed to QGuiGLFormat. We have the ability to introduce a pbuffer or similar other offscreen GL drawable abstraction in the future.
* | Add QEventDispatcherMac.Morten Sorvig2011-06-093-1/+18
| | | | | | | | | | Create it directly in QGuiApplication for now, later on we'll move it to the cocoa plugin.
* | Remove QPlatformEventLoopIntegration.Morten Sorvig2011-06-099-424/+17
| | | | | | | | | | | | | | | | Instead we'll let the platform plugins construct an QEventDispatcherQPA subclass. This API will be added later on. This temporarily breaks cocoa, uikit and opencode.
* | Cursor support in xcb plug-in.Laszlo Agocs2011-06-084-4/+40
| | | | | | | | | | | | | | Custom cursor pixmaps with depth greater than 1 are not yet supported and will be converted to monochrome always. Reviewed-by: Samuel Rødal
* | Avoid out of bounds writeLars Knoll2011-06-081-2/+4
| | | | | | | | Reviewed-by: Samuel
* | Fixed compilation with QT_NO_PRINTEROlli Werwolff2011-06-081-0/+2
| | | | | | | | | | Reviewed-by: Samuel Reviewed-by: Lars Knoll