summaryrefslogtreecommitdiffstats
path: root/src/compositor/wayland_wrapper
Commit message (Collapse)AuthorAgeFilesLines
* Compositor API: rename QWaylandInputDevice to QWaylandSeatJohan Klokkhammer Helsing2016-08-113-16/+16
| | | | | | | | | | | | The name QWaylandInputDevice could be confusing and misleading: - A QWaylandInputDevice was not one input device, but a collection of many. - Classes that sounded like they should inherit from it did not, i.e: QWaylandKeyboard, QWaylandPointer and QWaylandTouch. - The Wayland protocol already has another term for this, which is seat. Change-Id: I9d9690d5b378075d9dddaeb8cf18395c7f47603e Reviewed-by: Giulio Camuffo <giulio.camuffo@kdab.com>
* Compile with -no-openglJohan Klokkhammer Helsing2016-07-202-0/+12
| | | | | | | | | | | | | | QtWayland has not compiled without OpenGL for a while. This patch fixes the compilation issues and removes the old config variable, "QT_WAYLAND_GL_CONFIG" and instead checks for the presence of "opengl" in "QT_CONFIG". A new define is also introduced, QT_WAYLAND_COMPOSITOR_QUICK, because it may eventually be possible to use create a QtQuick compositor without OpenGL. Task-number: QTBUG-54322 Change-Id: Ica7b3b320212d4ae1f8b1053725b73c83739c73c Reviewed-by: Giulio Camuffo <giulio.camuffo@kdab.com>
* Compositor: Rename shm to sharedMemoryJohan Klokkhammer Helsing2016-07-112-5/+5
| | | | | | | | sharedMemory is much clearer and will increase the readability of the code and API. Change-Id: Ibb6d7424fa8d44a94a0f4ddf476a564eb235323f Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@hawaiios.org>
* Rename QT_COMPOSITOR_WAYLAND_GL to QT_WAYLAND_COMPOSITOR_GLJohan Klokkhammer Helsing2016-07-011-1/+1
| | | | | | | | Qt Wayland Compositor is the name used for the module elsewhere. Change-Id: I28813d50f1aed86f49a31aa54d27ea4ed2770d6a Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io> Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@hawaiios.org>
* Merge remote-tracking branch 'origin/5.7' into devLiang Qi2016-06-112-2/+12
|\ | | | | | | | | | | | | Conflicts: src/compositor/wayland_wrapper/qwldatadevice.cpp Change-Id: I2f555f969ec36b3e9b4123d758ae4176c5c90164
| * Compositor API: Clear drag icon when droppingJohan Klokkhammer Helsing2016-06-092-2/+12
| | | | | | | | | | Change-Id: I81f9645d1bc959e31f7663ab89bda285951331e7 Reviewed-by: Giulio Camuffo <giulio.camuffo@kdab.com>
* | Add dragStarted signal to QWaylandSurfaceJohan Klokkhammer Helsing2016-06-071-2/+4
| | | | | | | | | | | | | | This signal is emitted when starting to drag from the surface Change-Id: Ia949253833c7a0c6773810525ac1066e0db955fc Reviewed-by: Paul Olav Tvete <paul.tvete@theqtcompany.com>
* | Store and expose origin surface in QWaylandDragJohan Klokkhammer Helsing2016-06-032-1/+10
|/ | | | | Change-Id: Ic2bcc88f4ff375019ff7c6fe80ae4ec72205ca2d Reviewed-by: Paul Olav Tvete <paul.tvete@theqtcompany.com>
* Send data_source.cancelled event when dropping on nothingJohan Klokkhammer Helsing2016-05-301-0/+2
| | | | | | | | | | | I.e. on the wallpaper. This will fix a bug where dragging things onto the wallpaper in qwindow-compositor would make the drag icon stay there indefinitely. Change-Id: I19cb4e268346c3b4b624839939f295f64bf97aaf Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@gmail.com> Reviewed-by: Erik Larsson <erik@ortogonal.com> Reviewed-by: Giulio Camuffo <giulio.camuffo@kdab.com>
* Rename private headers to _p.hPaul Olav Tvete2016-05-193-3/+3
| | | | | | Change-Id: I0f0d1bd8efabc39325eec7dba4166ae0bccbf6ff Reviewed-by: Johan Helsing <johan.helsing@qt.io> Reviewed-by: Giulio Camuffo <giulio.camuffo@kdab.com>
* Fixed eglStream compositingDominik Holland2016-05-182-0/+9
| | | | | | | | | | | | | | | | | | | | | | | When creating the eglStream from the fd we also need to create the texture and call stream_consumer_gltexture. Otherwise the wayland client can't create the wayland client surface. Fixed the qwindow-compositor example to use the texture associated to the QWaylandBufferRef when compositing a EXTERNAL_OES target. QML compositing only works when QSG_RENDER_LOOP is set to basic as we need to generate a texture from the gui thread. As the texture is created by the bufferintegration it might end up in a different gl context than the quick item using it. The texture is also deleted together with the buffer, which prevents the use of the texture afterwards. Both problems need to be fixed in follow up commits. Task-number: QTBUG-50850 Change-Id: Ifec67bbe9e4b2a680c871dc4aced37b71b7b6f80 Reviewed-by: Louai Al-Khanji <louai.al-khanji@qt.io> Reviewed-by: Giulio Camuffo <giulio.camuffo@kdab.com>
* Don't send release events for uncommitted buffersJohan Klokkhammer Helsing2016-05-041-1/+2
| | | | | | | Fixes crashing GTK clients. Change-Id: I8d2717aa290a7a668af1b8b978447fbefd8ae665 Reviewed-by: Paul Olav Tvete <paul.tvete@theqtcompany.com>
* QtWaylandCompositor: Add support for different EGL buffer formatsLouai Al-Khanji2016-04-292-9/+12
| | | | | Change-Id: Idfeeedbf247fa81dccdf28a1aa04f878900ed262 Reviewed-by: Giulio Camuffo <giulio.camuffo@kdab.com>
* Compositor API: Add bufferScale property to QWaylandSurfaceJohan Klokkhammer Helsing2016-04-291-0/+1
| | | | | Change-Id: I1d4e4b65e5a58e3f314551bb10226fa58650becb Reviewed-by: Paul Olav Tvete <paul.tvete@theqtcompany.com>
* Compositor, drag-and-drop: Clean up drag focus when droppingJohan Klokkhammer Helsing2016-03-231-1/+4
| | | | | | | | | | | | Problem: If you dragged in one client, then closed that client, opened another one and tried to drag again, the compositor would crash. Solution: Reset the drag focus when dropping or canceling the drag operation. Change-Id: I0ab78b0a3e9d2889db225b7ca45957b5148bb3a0 Reviewed-by: Erik Larsson <erik@ortogonal.com> Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@gmail.com>
* Use WaylandCompositor module name for export macroPaul Olav Tvete2016-02-151-1/+1
| | | | | | | Change-Id: Ieb65b66f28986845f50647ae338678f0a1e7a153 Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@gmail.com> Reviewed-by: Erik Larsson <erik@ortogonal.com> Reviewed-by: Johan Helsing <johan.helsing@theqtcompany.com>
* Merge branch 'wip-compositor-api' into devPaul Olav Tvete2015-12-0253-8345/+458
|\ | | | | | | | | | | | | This introduces the new compositor API, removing the old API (which was never officially supported). Change-Id: I1dc01f0fb4edc749e34ed8356e56ad87d7d64913
| * Merge branch '5.6' into wip-compositor-apiLaszlo Agocs2015-10-273-2/+22
| |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | qwindow-compositor changes from 5.6 will be adapted separately. The traditional wayland-egl path is tested and is functional like before. The EGLStream support will be verified separately once the qwindow-compositor changes are ready. Conflicts: examples/wayland/qwindow-compositor/qwindowcompositor.cpp examples/wayland/qwindow-compositor/textureblitter.cpp examples/wayland/qwindow-compositor/textureblitter.h examples/wayland/server-buffer/client/client.pro examples/wayland/server-buffer/compositor/compositor.pro src/compositor/compositor_api/qwaylandbufferref.cpp src/compositor/compositor_api/qwaylandbufferref.h src/compositor/hardware_integration/qwlclientbufferintegration_p.h src/compositor/wayland_wrapper/qwlkeyboard.cpp src/compositor/wayland_wrapper/qwlkeyboard_p.h src/compositor/wayland_wrapper/qwlsurfacebuffer.cpp src/compositor/wayland_wrapper/qwlsurfacebuffer_p.h src/hardwareintegration/compositor/wayland-egl/waylandeglclientbufferintegration.cpp src/hardwareintegration/compositor/wayland-egl/waylandeglclientbufferintegration.h src/plugins/hardwareintegration/compositor/wayland-egl/wayland-egl.pro Change-Id: Ic2e3a6e8f74606c35b1e27cd4016fa133527d7ba
| * | Add warning to private headersPaul Olav Tvete2015-10-231-0/+11
| | | | | | | | | | | | | | | | | | | | | We mean it. Change-Id: I7381c7aad198dcca485d488571fd12296d07f980 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
| * | Merge branch 'qt/5.6' into wip-compositor-apiPaul Olav Tvete2015-10-135-0/+55
| |\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: examples/wayland/pure-qml/main.cpp examples/wayland/pure-qml/qml/Chrome.qml examples/wayland/pure-qml/qml/main.qml src/client/qwaylanddnd_p.h src/compositor/compositor_api/qwaylandquicksurface.cpp src/compositor/compositor_api/qwaylandsurface_p.h src/compositor/compositor_api/qwaylandsurfaceitem.cpp src/compositor/extensions/qwlinputmethodcontext_p.h src/compositor/hardware_integration/qwlclientbufferintegration_p.h src/compositor/hardware_integration/qwlclientbufferintegrationfactory_p.h src/compositor/hardware_integration/qwlclientbufferintegrationplugin_p.h src/compositor/hardware_integration/qwlhwintegration_p.h src/compositor/hardware_integration/qwlserverbufferintegrationfactory_p.h src/compositor/hardware_integration/qwlserverbufferintegrationplugin_p.h src/compositor/wayland_wrapper/qwlcompositor_p.h src/compositor/wayland_wrapper/qwldatadevice_p.h src/compositor/wayland_wrapper/qwldatadevicemanager_p.h src/compositor/wayland_wrapper/qwldatasource_p.h src/compositor/wayland_wrapper/qwlextendedsurface_p.h src/compositor/wayland_wrapper/qwlinputdevice_p.h src/compositor/wayland_wrapper/qwlinputmethod_p.h src/compositor/wayland_wrapper/qwlinputpanel_p.h src/compositor/wayland_wrapper/qwlinputpanelsurface_p.h src/compositor/wayland_wrapper/qwlkeyboard.cpp src/compositor/wayland_wrapper/qwlkeyboard_p.h src/compositor/wayland_wrapper/qwloutput_p.h src/compositor/wayland_wrapper/qwlpointer_p.h src/compositor/wayland_wrapper/qwlregion_p.h src/compositor/wayland_wrapper/qwlshellsurface_p.h src/compositor/wayland_wrapper/qwlsubsurface_p.h src/compositor/wayland_wrapper/qwlsurface.cpp src/compositor/wayland_wrapper/qwlsurface_p.h src/compositor/wayland_wrapper/qwltextinput_p.h src/compositor/wayland_wrapper/qwltextinputmanager_p.h src/compositor/wayland_wrapper/qwltouch_p.h src/compositor/windowmanagerprotocol/waylandwindowmanagerintegration_p.h src/imports/compositor/WaylandCursorItem.qml Change-Id: I4e63ef295b297022d4970b3c68b3d565843086bd
| * | | A surface buffer has content iff it has a bufferPaul Olav Tvete2015-10-121-1/+1
| | | | | | | | | | | | | | | | | | | | Change-Id: I357097740a50b677b85e1708ec440da03573d2d2 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
| * | | Remove the QWaylandOutputSpaceJørgen Lind2015-09-181-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We don't need this abstraction anymore since we don't have global coordinates in the core api anymore Change-Id: I553a736a0e71026447d6a0af3f8a64607b8c8f06 Reviewed-by: Paul Olav Tvete <paul.tvete@theqtcompany.com>
| * | | New API for drag and dropPaul Olav Tvete2015-09-172-77/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Let the compositor implementation keep all the GUI state. Change-Id: I73a865fa3407340276d6765e10378b8e23a76fe2 Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
| * | | Return empty size when nil buffer is attachedPaul Olav Tvete2015-09-161-0/+3
| | | | | | | | | | | | | | | | | | | | Change-Id: I74d46c9d2639315341a1e101e304cdffd748976c Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
| * | | Remove the mouse grabberPaul Olav Tvete2015-09-152-65/+64
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is no longer used for move/resize, and we are going to introduce a new concept for drag and drop (which stopped working several changes ago anyway). The old drag and drop code is left commented out to assist in the new implementation. Change-Id: I18cb41d04f09d6033d1c9e666a739793fcef494b Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
| * | | Remove global coordinatesJørgen Lind2015-09-141-7/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This involves removing: - pickView and mapView from QWaylandOutput - requestedPos[X,Y] from QWaylandView Change-Id: Ie53eef434ac6ae7d0d5474f649f78a59ae857167 Reviewed-by: Paul Olav Tvete <paul.tvete@theqtcompany.com>
| * | | Rename QtCompositor to QtWaylandCompositorJørgen Lind2015-09-1010-20/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | enable building QtWaylandCompositor by default Change-Id: I7cf34052b304ca9fef55b7e30ef6a6367b5d75f1 Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
| * | | Remove automatic initialisation of extensionsJørgen Lind2015-08-286-465/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It is the specific compositor application responsibillity to create the specific extensions. Some of the extensions are picked up with the QWaylandExtension::findIn(QWaylandExtensionContainer *) function to work around missing events/apis. It should be a goal not to have these calles in the base implementation of QWayland[Compositor|Surface|Input..]. Change-Id: Iacd576f2e8a79ca0165b858b1e8f44cddad48d93
| * | | Move qwltouch_p.h into qwaylandtouch_p.hJørgen Lind2015-08-283-269/+0
| | | | | | | | | | | | | | | | Change-Id: Id93b3d70fa97307d905300dc4fc842bcf5ce5f1d
| * | | Remove the qt_sub_surface extensionJørgen Lind2015-08-281-187/+0
| | | | | | | | | | | | | | | | Change-Id: I380590722f2c95ff68972f5b3c94a7cc4cfe016f
| * | | Move QWaylandKeyboardPrivate away from wayland_wrapperJørgen Lind2015-08-285-534/+2
| | | | | | | | | | | | | | | | Change-Id: I77dce1eecdda21f4a9907d1cd7fafe23de326136
| * | | Move QWaylandPointerPrivate into a _p file and remove the apiJørgen Lind2015-08-285-358/+2
| | | | | | | | | | | | | | | | | | | | | | | | and make sure all other classes uses the public QWaylandPointer type Change-Id: Ie7ff24160c253ff700eb27eb46788fe021386dd7
| * | | Remove QtWayland::InputDeviceJørgen Lind2015-08-288-484/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | and add QWaylandInputDevicePrivate. Also make sure noone holds a reference to the private instance. Change-Id: Ic2327595d58d6308e1e2699370f53aef47061b04
| * | | Remove the QtWayland::Output classJørgen Lind2015-08-283-605/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | and add QWaylandOutputPrivate. Also make sure no other class holds a pointer to the QWaylandOutputPrivate but only to QWaylandOutput Change-Id: I6c5914d5bf9b394c6fbd7e181e603076fbdc79d7
| * | | Remove QtWayland::Compositor and add QWaylandCompositorPrivateJørgen Lind2015-08-2817-923/+41
| | | | | | | | | | | | | | | | | | | | | | | | Embrace PIMPL Change-Id: I8c8b5971e15c208317ff33231bda1513e7b8d489
| * | | Move some virtual functions into protected scoping.Jørgen Lind2015-08-282-3/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Users should not call these functions, but they should be able to sub-class QWaylandCompositor to reimplement them Change-Id: I35888fec67bec085820733135f201bab1df268a3
| * | | Remove QtWayland::SurfaceJørgen Lind2015-08-2817-673/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Its enough to have QWaylandSurface and QWaylandSurfacePrivate. Also don't pass QWaylandSurfacePrivate around, but pass QWaylandSurface and then use the QWaylandSurfacePrivate::get function. Change-Id: I915cc9d7b4497ad1c6f1f2dee61d9d0db069ba6b
| * | | Remove the Surface role functionalityJørgen Lind2015-08-282-75/+0
| | | | | | | | | | | | | | | | | | | | | | | | This replaced by the QWaylandExtension and QWaylandExtensionContainers Change-Id: Iba0299725542ede618b636fb2d40715acfcb3b51
| * | | Remove output from QWaylandSurfaceJørgen Lind2015-08-285-39/+41
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It is the views that belong to outputs. This leads to a couple of interesting cases with enter and leave events, but the implementation says you will get enter events for the first view of a surface entering an output, and for the last view being removed from an output. Also to throttle a surface, there has to be 1 surface which takes care of this. This is because if multiple views throttle, then the client might render to quick. Change-Id: If4bba380fd4d7f506fd769606cbdea4ce58b908d
| * | | Fixups after rebasingJørgen Lind2015-08-285-24/+26
| | | | | | | | | | | | | | | | Change-Id: Ie5d8899157d77f83f2cf65f236d534b972aa4770
| * | | Remove excess definition of QWaylandKeymapJørgen Lind2015-08-285-34/+11
| | | | | | | | | | | | | | | | | | | | | | | | Also remove QWaylandUnmapLock Change-Id: I0b481224fd03032603084142f36be279351f6611
| * | | Remove the default shell functionalityJørgen Lind2015-08-281-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This will be readded in a different way. Also, remove the WaylandSurfaceChrome since it is no longer needed, and just use WaylandView directly Change-Id: I8d4a7b2135d9fdaea7dd3fcd729e55cceebf48fb
| * | | Remove unused includeJørgen Lind2015-08-281-1/+0
| | | | | | | | | | | | | | | | Change-Id: Icdcc1915ab5ddac8e49ae46476e897c8f5c449e0
| * | | Remove the QWaylandCompositor::createView virtual functionJørgen Lind2015-08-282-7/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Views are just a representation of the QWaylandSurface, and many different types of view "sub-classes" will exist depending on its perticular use. Dont enforce just one view implementation for one compositor. Change-Id: Ie237a73e63638e70713f89b479fb1b248426c9ac
| * | | rename QWaylandExtensionTemplate::get to findInJørgen Lind2015-08-285-7/+7
| | | | | | | | | | | | | | | | Change-Id: I7fcfd2e4974cf1b5b32592a6d5c03ed335a9f446
| * | | Rename QWaylandSurfaceView to QWaylandViewJørgen Lind2015-08-2812-48/+48
| | | | | | | | | | | | | | | | | | | | | | | | and rename QWaylandSurfaceItem to QWaylandQuickView Change-Id: I989b482eb79df06e9f265bc2b0ef6b3dce7509d6
| * | | Improve QWaylandExtensionJørgen Lind2015-08-281-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | By using curiously recurring template pattern we can generate a getter which is very convenient, and all QWaylandExtensions should have this casting operation Change-Id: Idb5a786655f2e106cf5388b11ed71e8b6ddddec0
| * | | Remove transient(inactive|parent|offset) from QWaylandSurfaceJørgen Lind2015-08-285-28/+10
| | | | | | | | | | | | | | | | Change-Id: I0fad382c0baa13ec72ff5e45cc1eba0bd4d5c70a
| * | | Remove the static instance of a compositor.Jørgen Lind2015-08-283-13/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | All classes that needs to access the compositor instance needs to keep a reference to it Change-Id: Ia0d4b04b460200ad3c7907b94c032afe90c18771
| * | | Make it possible to subclass QWayland(Pointer|Keyboard|Touch)Jørgen Lind2015-08-282-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | by having factory functions on QWaylandCompositor and use them from QWaylandInputDevicePrivate Change-Id: Id5e0413ca1fb40e2f7eba571dda361b2809fe313