summaryrefslogtreecommitdiffstats
path: root/src/compositor/wayland_wrapper/wlinputdevice.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Port to libxkbcommon 0.2.0.Giulio Camuffo2012-11-051-4/+4
| | | | | Change-Id: If2b76317c5c5addcbc45c0b3212cd2ce72ceab9c Reviewed-by: Andy Nichols <andy.nichols@digia.com>
* Change copyrights from Nokia to DigiaIikka Eklund2012-09-251-6/+6
| | | | | | | | Change copyrights and license headers from Nokia to Digia Change-Id: Ie65cbe0c622780d2f0672bce19d267d1167620ff Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com> Reviewed-by: Jørgen Lind <jorgen.lind@gmail.com>
* Fixed modifiers not working for non-Qt wayland clients.Samuel Rødal2012-09-221-1/+49
| | | | | | | The compositor needs to keep track of the modifiers now. Change-Id: Idc865744e1fdc05ced276ad766b2ce095fb207f5 Reviewed-by: Jørgen Lind <jorgen.lind@gmail.com>
* Made qtwayland compositor handle plain wayland clients.Samuel Rødal2012-09-221-0/+76
| | | | | | | | | | | | Wayland clients now expect to receive a compiled xkb keymap from the compositor. Update libxkbcommon_sha1.txt to newest and send a keymap to the clients (for now just evdev/pc105/us). Change-Id: I89e99f05d8a98a7de83b8985a370de4fa39074a6 Reviewed-by: Arvid Picciani <aep@exys.org> Reviewed-by: Jørgen Lind <jorgen.lind@gmail.com>
* Prevent crashing the compositor when the client wants to unset the cursor.Samuel Rødal2012-09-221-1/+3
| | | | | Change-Id: I40460110e24555aacaef928af32372c32a3291d1 Reviewed-by: Jørgen Lind <jorgen.lind@gmail.com>
* qtwayland: correct order of parameters in setMouseFocus()Elvis Lee2012-08-201-1/+1
| | | | | | | | Examined it's callers in qtwayland. And it's supposed that there is no extenal callers, not in qtwayland. Change-Id: Id9b42b03e0718f27dc7be3f987bb077092d3a06f Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
* Fix broken handling of inactive transient surfacesLaszlo Agocs2012-06-181-1/+8
| | | | | | | | | Makes tooltips and tooltip-like components like Create's locator show up properly. These should never get keyboard focus even though they are regular surfaces like any other. Change-Id: I0ade61845d9785cad19040683362a5532a04e6f6 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Bump shaLaszlo Agocs2012-06-041-1/+1
| | | | | | | | | | | keyboard_modifiers is not yet sent from server side (in qt-compositor) on keyboard focus, this needs to be added later. Unfortunately the event is somewhat libxkbcommon-specific... Also move/removed some unused variables. Change-Id: Id971bdc3a0e217740593d23145fc4ebb27d99a06 Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Make axis events compatible with WestonLaszlo Agocs2012-05-201-1/+1
| | | | | | | | From now on mouse wheel events will work both with qt-compositor and Weston. Change-Id: I54876cd45f3530ea9b4b7962ca52c0974e1cb2d5 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Migrate from wl_input_device to wl_seatLaszlo Agocs2012-05-201-104/+238
| | | | | Change-Id: I0d218c32478c2acce4d7012bdb26b0cde50ee633 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Make sure the pointer focus is really reset when destroyingLaszlo Agocs2012-05-101-1/+1
| | | | | | | | Using the grab interface introduced an issue which crashes the compositor quite often when running widget apps. Change-Id: I74b64fb7b18ec510773b3b533a3c778be7173db4 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Add wheel event supportLaszlo Agocs2012-05-101-0/+11
| | | | | Change-Id: Id827485138758ccb4c0db420559b2b9af5c45bbc Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Start using the new wl_fixed_t type properlyLaszlo Agocs2012-05-091-17/+19
| | | | | | | | | | | | | | The mouse and touch coordinates cannot just be treated as integers anymore, they need to be converted from/to double using the helper functions. Some necessary QPoint -> QPointF changes have also been made. For the Qt-specific touch extension we will not switch to wl_fixed_t though. This is because the precision is unfortunately quite small (factor of 256 vs. 10000). Change-Id: I23deaaffe478a39495b12d336985bc62e38a6af4 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Sync up with the latest wayland developments.Hannu Lyytinen2012-04-191-6/+8
| | | | | | | | | | This commit makes the qtwayland module compatible with wayland sha1 677c5180e67be18b7a0867fafb7f205b57a6e9ff. Change-Id: I5af0510034b7e4a038313b80f1f6e0b18fa48eb3 Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com> Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Implement so that Compositors can use the wl_pointer_grab interfaceJørgen Lind2012-04-111-24/+22
| | | | | Change-Id: Idaed835ef25a820cba388831c9ecdcf0f5de20f2 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Update wayland_sha1 and implement buffer_pool interfaceJørgen Lind2012-04-101-6/+11
| | | | | Change-Id: I0628a7655a6deb061a5d0b6c6304c89d8655cf11 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Change the touch extension to be always available.Laszlo Agocs2012-03-281-3/+1
| | | | | | | | Not opt-in anymore. Clients that connect to the extension will get the extended touch events, others will get the regular events. Change-Id: I91daec1949814fff5cfa0ebcc82c0977eee963b7 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Enable the qtkey extension regardless.Samuel Rødal2012-03-281-3/+1
| | | | | | | | | | Now the clients get qtkey events if they register themselves against that interface, otherwise they get regular key events. This handles both qt clients and pure wayland clients being connected at the same time, sending qtkey events to the former and regular key events to the latter. Change-Id: Iebd9d78b57758b45098b99a94414ee428e41636b Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
* Added qtkey extension to send raw QKeyEvents over the protocol.Samuel Rødal2012-03-271-0/+20
| | | | | | | | | For Qt based compositors we already have the full QKeyEvent, so we might as well send it over the wayland protocol. This pretty much mirrors the touch extension we already have. Change-Id: I922f0cab6fe137272744762d6c57a31056b45672 Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
* Use the new cool event wrapper functions generated by wayland-scannerJørgen Lind2012-03-051-21/+17
| | | | | | | | | | This gives us some more static typechecking which is cool.. This fixes actually a couple of minor bugs we had, one where we didn't send a value for the refreshrate of a screen, and a couple in selection. Change-Id: I2b4193b488784885d7cce27f7f5b2d2df45c6c83 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Upgrade to newer wayland SHA-1.Samuel Rødal2012-03-051-1/+1
| | | | | Change-Id: If0c1d86a3011e266cafabeb875bc5616191a8cf4 Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Add '16 mouse buttons' feature to InputDevice::toWaylandButtonRick Stockton2012-03-031-8/+20
| | | | | | | Task-number: QTBUG-22759 Change-Id: Id886a61a98e07bfeb4a18ef57905d6b7293ca0c8 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Improve wayland_cast and introduce resolve to simplify code.Samuel Rødal2012-03-021-3/+3
| | | | | | | Resolves the wl_resource by accessing the data member. Change-Id: I10912acea0a3ca6abbc067d07d43a46ec65a77aa Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
* Compositor memory leak fixesLaszlo Agocs2012-02-151-3/+10
| | | | | Change-Id: Ia0510e00ffc925cde98ec5345a8129d1979c478c Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Removing Wayland::SurfacePrivateJørgen Lind2012-02-131-1/+1
| | | | | | | | | | | | | | | 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>
* Add TouchCancel support.Laszlo Agocs2012-02-101-0/+5
| | | | | | | It maps to the protocol's touch_cancel pretty well. :) Change-Id: Id417aac768106c2f6618b3e7ecb51d6929977c37 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Fix data device handling.Laszlo Agocs2012-02-071-3/+7
| | | | | | | | | 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>
* Remove "All rights reserved" line from license headers.Jason McDonald2012-01-301-1/+1
| | | | | | | | | | | 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>
* Update obsolete contact address.Jason McDonald2012-01-231-1/+1
| | | | | | | | Replace Nokia contact email address with Qt Project website. Change-Id: Ib67c393df41c539deae0ef71e0acc13029ceb46d Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Update license headers.Jason McDonald2012-01-161-17/+17
| | | | | | | | | | All code in this module outside of src/plugins/platforms/wayland should carry a copy of the BSD license header. The master copy of this header lives at qtbase/header.BSD. Change-Id: Icd56f24f4a3d309db4c1c3aaef25618680c07f6e Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Introduce a touch protocol extension.Laszlo Agocs2012-01-131-4/+12
| | | | | | | | | | | | | | | | | | | Using this opt-in protocol extension all data from QTouchEvent will properly be delivered to the clients. By default compositors will still use the standard and limited protocol for touch events to remain compatible with non-Qt clients. However by calling enableTouchExtension() in the compositor, touch events will be sent through the new protocol and thus Qt clients will receive proper QTouchEvents. Non-Qt clients will get no touch data in this mode. The contents of the rawScreenPositions() list are not yet delivered as the size implications remain to be checked. Change-Id: I981b9c4d44ea808a95b770bf948320abd47fc036 Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Make touch event sending more robust in the InputDevice.Laszlo Agocs2012-01-111-5/+15
| | | | | | | | | At least it won't crash and proper warnings are shown when the slightly obscure pointer focus is not used properly in the compositor. Change-Id: I2c970d197176b588f38a750e3cc805aae4d6c049 Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Don't crash when sending touch events.Laszlo Agocs2012-01-111-1/+1
| | | | | | Change-Id: I62bf4913338e6daa3245400b0e2c7004907cb29a Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Move event handling into WaylandInput apiJørgen Lind2012-01-111-8/+173
| | | | | | | | | | | | | Qt only gives us 1 input device as of now, ie. the mouse/keyboard and touch events. However, at some point in the future, this will change, so that the events will have a device id. This will ie on x map to the same device, but on evdev this can be different devices. Also this is part of what is needed to implement grabbing Change-Id: Ice049502d6f0f53fd06142d4dedde05806d60120 Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
* Make QtCompositor work with wayland-demo clients.Jørgen Lind2011-12-201-5/+7
| | | | | | | | | | Make it possible to have >1 registered frame callbacks Also remove the QShmBuffer destory callback, since we should use destory listeners instead. Change-Id: I407fc2075f62aaf9f042e85b003b3aaf7ee72cf5 Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
* Added a resourcecollection classJørgen Lind2011-12-141-2/+3
| | | | | | | | | | This class will typically be the super class of globals which creates wl_resources in the bind functions. If for some reason some other class needs to get a resource for a given client of the global, it can look it up Change-Id: I939cc7aaeb15586f2c760c600c188a8cbf19f358 Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
* Make wayland actually a moduleJørgen Lind2011-12-071-0/+152
Also fix so that QtCompositor can be built as shared object. + fix so that the default QT_WAYLAND_GL_CONFIG is wayland_egl Change-Id: I02b72e99286584426bd37ab2d00bbc84af11efdc Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>