summaryrefslogtreecommitdiff
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* Improve wayland_cast and introduce resolve to simplify code.Samuel Rødal2012-03-0210-35/+46
| | | | | | | Resolves the wl_resource by accessing the data member. Change-Id: I10912acea0a3ca6abbc067d07d43a46ec65a77aa Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
* Get rid of warnings in compositor source.Samuel Rødal2012-03-029-5/+39
| | | | | Change-Id: I8977e370e1036bf1722b5e88fc6cc3ade9a2d9a9 Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
* Got rid of warnings in wayland plugin source.Samuel Rødal2012-03-026-2/+26
| | | | | Change-Id: Id3b39213da79daff2ea952eb0ba90272f98a7da7 Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
* Avoid flicker when switching back to composited modePaul Olav Tvete2012-03-023-10/+42
| | | | | | | | The surface item needs to create a new texture when the compositor switches from direct render to composited mode. Change-Id: Ic2d65929617f1941ea290645ac28b8e986c414bc Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Make direct rendering work after QPlatformScreenBuffer refactoringPaul Olav Tvete2012-03-014-15/+15
| | | | | Change-Id: Iebd082678264178987e2550370663ed2b44a8916 Reviewed-by: Andy Nichols <andy.nichols@nokia.com>
* Make SurfaceBuffer a QPlatformScreenBufferJørgen Lind2012-03-019-62/+143
| | | | | | | | | And refactor to make it fit Done with: Paul Change-Id: I2bd28abb4ac256a336cd6c2c90e67104d8c27cc5 Reviewed-by: Andy Nichols <andy.nichols@nokia.com>
* Add accessibility to wayland.Frederik Gladhorn2012-03-012-0/+10
| | | | | | | The QPlatformAccessibility class simply loads the needed platform plugins on demand. Change-Id: I9c384b6bb9244379bc14902489170f8877c49a2f Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Compile fix for the new DND interfacesJørgen Lind2012-03-012-3/+4
| | | | | | | This doesn't mean the DND works for the wayland plugin yet Change-Id: I6a4ae57e4b19dcedaf10119e033d5cbead8cb19d Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Added warning for when xkb_compile_keymap_from_rules fails.Samuel Rødal2012-03-011-0/+3
| | | | | Change-Id: I9b0bde8cc8d2575963db2e3165919b2d78213424 Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Load the module so we get the correct QT_CONFIGJørgen Lind2012-02-291-0/+2
| | | | | | | We need this to autodetect if we'r going to build WaylandSurfaceItem Change-Id: Icdd5379d8334422ff4f780bf5192e9c01101e9db Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* conform to new plugin apiJørgen Lind2012-02-293-2/+9
| | | | | Change-Id: I42c05384767989aa95b49abfadd875d0f8b157d4 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Refactor wlsurface,Jørgen Lind2012-02-294-172/+187
| | | | | | | | Now we treat all buffers the same (shm or not). We advance the queue when we send the frame signal Change-Id: Id62b1037e03fbeae82048f5ab9078fa81ed8e45d Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Removed obsolete src/plugins/platforms/wayland/wayland_sha1.txtSamuel Rødal2012-02-281-3/+0
| | | | | | | The wayland_sha1.txt in the root folder is the correct one. Change-Id: Ic843dc3110e6d71fbb031691312848369e448e06 Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
* Get rid of some code in wayland plugin.Samuel Rødal2012-02-272-39/+8
| | | | | | | We can use the convenience API that has been added to wayland instead. Change-Id: I9516256a14f62593b3c78064a0f6288bb496c583 Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Support ShowIsFullScreen in plugin and compositor.Samuel Rødal2012-02-2313-5/+90
| | | | | | | | Added way of controlling client side style hint ShowIsFullScreen from compositor, and added support in plugin for the WindowFullScreen state. Change-Id: I60efa5692b26e9a4079c3c2fb66eb72b67badd02 Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
* Make glx backend compiling again after qtbase broke the includesLaszlo Agocs2012-02-211-0/+1
| | | | | Change-Id: I2bbbdad7fdd0c726316a4192240a00326fd4d72e Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Don't send Deactivate events when creating WaylandSurfaceItemLasse Holmstedt2012-02-201-1/+3
| | | | | | | | The default state is Deactivate, so getting extra ones at startup is not needed. Change-Id: I9c6b4b5dab58651f1933900421a3d6d68e00522f Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Fix issues with sendOnScreenVisibilityChangeLasse Holmstedt2012-02-204-3/+8
| | | | | | | | Initialize variables and send the event in the beginning so that we can be sure both client and server are in sync. Change-Id: Ibabd2fa3cfc2c7defd4804f3fcbdd184eba46652 Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Call the correct frameFinished method in Surface::sendFrameCallbackAndy Nichols2012-02-201-1/+1
| | | | | | | | After the recent refactoring, the frameFinished method was still called where we should now be calling frameFinishedInternal Change-Id: I6ac5c0467dda6bb7e62976e8da28dc9d19a986c8 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Fix wayland plugin and qwindow-compositor compilationLaszlo Agocs2012-02-201-1/+1
| | | | | | | | | Apparently some qtbase change triggers the need to include a bunch of headers which were not properly included before. The extra mouse button support in the platform plugin simply did not compile. Change-Id: I7d518021fa81f2d5232277f0bce26e48effbeae3 Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Send mouse release generated from TouchCancel to the proper windowLaszlo Agocs2012-02-201-1/+1
| | | | | Change-Id: I3d0ab79eb261de4d22c6aadf0672f5c84ff3533e Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Compositor memory leak fixesLaszlo Agocs2012-02-1514-14/+81
| | | | | Change-Id: Ia0510e00ffc925cde98ec5345a8129d1979c478c Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* qtwayland: Add support for 16 mouse buttonsRick Stockton2012-02-151-2/+41
| | | | | | | | | | | | | | | | | Update expands the mouse button assignment code block, which formerly handled only values 272, 273, and 274. New version handles all mouse mouse buttons shown in kernel's input.h header (decimal values 272 through 285). Value 286 appears to be the first button in the range for joystick devices, so I did not include any other kernel-enumerated values. (Other values might be possible- but I don't know of a mouse which is currently being sold with more than 15 non-wheel buttons. The mouse with 15 buttons is the Razer Naga, and I don't own it.) Task-number: QTBUG-22759 Change-Id: I77f16eb89e24d7d6410199badff28c0d48f7df93 Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Expose in a virtual function that surfaces are being destroyedJørgen Lind2012-02-154-1/+8
| | | | | Change-Id: I979e7d9ca7152d4db6c3e7adae8353935a05d6c5 Reviewed-by: Andy Nichols <andy.nichols@nokia.com>
* Pass the correct window on to QWindowSystemInterface.Samuel Rødal2012-02-141-2/+2
| | | | | | | | | | | | | | Sometimes, the window's coordinate system is not bounded by the coordinates of the QScreen (such as if the window uses a landscape window orientation on a portrait screen). QGuiApplication::topLevelAt() will fail to find this window, but since we have the window already at the wayland plugin level we just use that. We already did this for mouse events, so it's natural to do it here as well. Change-Id: Id086dd940aa1cf4eb4480117d243ab8a76da6cca Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
* Added convenience properties in WaylandSurface for window orientation.Samuel Rødal2012-02-1410-2/+58
| | | | | | | | | The new windowRotation property is especially useful for the compositor to know how much the surface needs to be rotated in order to be displayed correctly. Change-Id: I81ee17880ceafd465c39b4439dee978f2cb80924 Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Prevent occasional crash in qwaylandinputdevice.cppSamuel Rødal2012-02-131-1/+1
| | | | | Change-Id: I86559add9925dad6aef530433dd92066f1708757 Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
* Removing Wayland::SurfacePrivateJørgen Lind2012-02-1315-555/+601
| | | | | | | | | | | | | | | And moving Wayland::SurfaceBuffer into its own file. Also remove the extra functions in Wayland::Surface which just relayed down to extended surface. The pattern is that WaylandSurface is the entry point so we check there is the Wayland::Surface has the extension we'r looking for, then calling it directly from WaylandSurface. Last, the data of an extension is suppose to be members of the extension, so I moved the properties to be members of ExtendedSurface Change-Id: I5877671a17ee873b7644094f695fcd3e4677964a Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Fix surface wrapper build when QT_COMPOSITOR_WAYLAND_GL is not setLaszlo Agocs2012-02-131-2/+2
| | | | | Change-Id: Ic03d08ec936059344a1e092329a9def0b4ceb9ee Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Fix build of compositors by always including QOpenGLContext.Pier Luigi Fiorini2012-02-121-1/+1
| | | | | | | | | QOpenGLContext is always required even when QT_COMPOSITOR_WAYLAND_GL is not defined. Moving the include outside the ifdef makes compositors build without problems. Change-Id: I4b8903b06a5f58ad8fd2953dbde1476877683cb4 Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
* Surface::isInverted Dont use xor and move the ret variableJørgen Lind2012-02-121-3/+2
| | | | | | | outside the ifdef Change-Id: I6f9048cd7d5992ef46dcc0e9d05e86f2f7ca4033 Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
* Added window flags to the surface-extension protocolGunnar Sletta2012-02-1011-2/+83
| | | | | Change-Id: I1b53c5f0b0f908490dcd0ab30e46ab681f885954 Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Add TouchCancel support.Laszlo Agocs2012-02-104-5/+36
| | | | | | | It maps to the protocol's touch_cancel pretty well. :) Change-Id: Id417aac768106c2f6618b3e7ecb51d6929977c37 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Remove hack that causes deadlock when waiting in eglSwapBuffersAndy Nichols2012-02-102-36/+20
| | | | | | | | | | | This hack was added to work around the problem of calling wl_display_iterate in two separate threads, but now that we are are enforceing that wl_display_iterate can only be called in one thread it now causes a deadlock when we are waiting in eglSwapBuffers for the gui thread to actually call wl_display_iterate. Change-Id: Id3153b184c191494838fc363380f7cae621ac64e Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Fix data device handling.Laszlo Agocs2012-02-072-3/+10
| | | | | | | | | Clearing the device list on resource destroy is wrong: it cleans away data devices for all clients. Calling free when removing stale devices for a client is also wrong. Change-Id: I7bfcc928762dc4ca7dbf5abeebcd2489956e6828 Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Add mouse event synthesizing to the touch extension protocol.Laszlo Agocs2012-02-078-9/+62
| | | | | | | | | The compositor can now be configured to tell the clients to generate mouse events when receiving touch events. In touchscreen-only systems this can be used to reduce the number of Wayland events. Change-Id: I231a15cd4ed463ee81c510c082a270efa255a1f3 Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Set pointer focus to null when surface is destroyed.Laszlo Agocs2012-02-031-0/+2
| | | | | | | | | We must do something otherwise the next inputDevice->mouseFocus() call will dereference an already deleted instance. Change-Id: I3ac92a37715f63c6dc43191968a8da51befbccde Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Don't try to carry over qPrintable() pointersLasse Holmstedt2012-02-033-5/+4
| | | | | | | | | The pointer is out of scope by the time it's sent through wayland. Change-Id: I00e9f050dfa47bf078921600d2bf63502f0b4897 Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Ian Monroe <ian.monroe@nokia.com> Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
* Fix mouse handling in qml-compositor.Laszlo Agocs2012-02-021-0/+2
| | | | | | | | | | | The pointer focus must be set in pressed. We cannot rely on the implicit mouse tracking behavior of QWindow for QML stuff because the WaylandSurfaceItems will not get mouse moves outside of a press-release sequence. Change-Id: Ic2cf2a7497cac7397bcfa26440dd05cded6182dc Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Added reporting of window and content orientation to surface extension.Samuel Rødal2012-02-0110-1/+131
| | | | | | | Change-Id: I6e182c048282f5edd30f49be19dcc0f020679b85 Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com> Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Revert "Do not attach null buffer."Laszlo Agocs2012-01-301-0/+2
| | | | | | | | | | | This reverts commit 42ed12656016a96b966b7b5e52f0b684ad65c227. Weston has been fixed so attaching null buffer on hide is now a valid operation. Change-Id: I0fc6af7f87c97e07075da03ed1b54d2e3c1d45fd Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Do not attach null buffer.Laszlo Agocs2012-01-301-2/+0
| | | | | | | | | | | Apparently Weston does not like this and causes instant crashes when hiding a top-level widget. The QtCompositor-side behavior is dubious too although at least that does not crash. Nevertheless attaching a null buffer seems unnecessary. Change-Id: I1d7fe3e0b05e5d77773b661a71bc37311968eded Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Null out the frame callback ptr properly.Laszlo Agocs2012-01-301-0/+1
| | | | | | | | Otherwise shm based apps (widgets) will crash randomly. Change-Id: I5345ca9419a6702170f93fd817bbab4d9ef2bc59 Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Remove "All rights reserved" line from license headers.Jason McDonald2012-01-30144-144/+144
| | | | | | | | | | | As in the past, to avoid rewriting various autotests that contain line-number information, an extra blank line has been inserted at the end of the license text to ensure that this commit does not change the total number of lines in the license header. Change-Id: I08d8673382f0230d5c5a22a25efaf5c45cef539a Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Fix compilationLaszlo Agocs2012-01-271-0/+1
| | | | | | Change-Id: Ia3e62ed30467bb52555c353a30440ebcc3529d0b Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Add possibillity of overriding invertedY flag for wl_surfacesJørgen Lind2012-01-261-6/+12
| | | | | | Change-Id: I0f4c2696ae5c7071275af326c924dc1eaed6d5b6 Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Andy Nichols <andy.nichols@nokia.com>
* Make it possible not to have queing of buffers on the serversideJørgen Lind2012-01-261-11/+12
| | | | | | Change-Id: Ic7d3221321e2d7ecc69e56b7ad7a23322e65995d Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Andy Nichols <andy.nichols@nokia.com>
* Revert "Do not generate mouse event on the first motion event."Laszlo Agocs2012-01-261-8/+5
| | | | | | | | | | | | This was a misunderstanding. The default (and the only) behavior with QWindows is to have mouse tracking enabled. QML or QApplication can then filter out the button-less moves, if needed. This reverts commit bd0681daf6fa91afee16bba619f17b7bd3bd5460. Change-Id: I2f641a2826e1578f103d1e29939b661cbae4fcc2 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com> Sanity-Review: Samuel Rødal <samuel.rodal@nokia.com>
* Do not generate mouse event on the first motion event.Laszlo Agocs2012-01-261-5/+8
| | | | | | | | | | This event comes before the button event and thus must not result in a Qt mouse event. Instead, the button event will generate the MouseButtonPressed with the position sent in this motion. Change-Id: I97887d4d5fcd54575d6f4e9523a04569424c0bc2 Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Added missing include to fix build.Samuel Rødal2012-01-251-1/+1
| | | | | | | | | Fixes build after change in qtbase requiring Q_DECLARE_METATYPE(T*) to be fully defined. Change-Id: I741d91eb0e7e480b5a35a4616b32a90043f01a63 Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>