Support changing the keymap

This adds new API, but does not add a way for the user to set the
keymap. That should be implemented in the compositors.

Change-Id: I28ee7d372f8f578c0d7efb9223cabce49504be1f
Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@gmail.com>
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
Updated required version

Change-Id: I0284bcac551c13d3f8a7e71c00f0f68cd7872f08
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Fix build break

Remove the removed argument from the EGL platform context constructor.

Change-Id: I6203d07c356f7191a698d8d5bc958923cbdc2d96
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
Remove the buffer queue.

A client calling attach(A);commit();attach(B);commit() should result
in its back buffer be set to B, and A be discarded.
If the client wants to have a queue it should keep it client side or
a protocol extension tailored for that purpose should be developed.

Change-Id: Ia0048f311504d85821df9f5b9225887801efec71
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
Make sure the frame callbacks are sent at the right time

When there is a rendering thread, like with QtQuick compositors,
there is a race condition where the frame callbacks are sent before
the last buffer the client sent is released.
Assume the following scenario:
attach(B1)/frame(F1)/commit()...frame started...attach(B2)/frame(F2)/
commit()...frame finished.
On frame finished the callback just installed is emitted before the
buffer B2 is being used and B1 released. That forces the client to
allocate a third buffer to draw the next frame.
Now, do not send out the frame callbacks until a new frame started.
The successive draw will release B1, use the new B2 and than send out F2.

Change-Id: I5743c7baf9fdd3cde28c5f594ff646c06abb74b7
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
Compile ServerBuffer client example on desktop gl

Change-Id: I8efbda3e5266c5668b2461429a21d900e2ecd175
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Fixup for GLX integration

Change-Id: I2de94481f7d3e109fdce7ca961f8969299cf5d9e
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Take advantage of the Qt 5 plugin json structure

Also change naming scheme of plugins:
buffer integrations doesn't start with "wayland-" but the platform
plugins have to start with "wayland-".

Also update the README

Change-Id: I6dd2103ab287ed569ab06cfb6eb469e3db058831
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Flush the clients connection after sending the frame callbacks

We want to make sure the events reach the clients asap.

Change-Id: I0783c6be4f4412fd5f3665faec1e57d141291ce7
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
Make the compositor redraw when a surface gets a commit().

It must redraw, even if it doesn't actually redraw anything, irrespective
of the fact that a attach/damage has come or not. Just calling frame();commit()
is perfectly valid.

Change-Id: If298654b8a7cb7c954cfbad8618f23134731cb9f
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
Fix NPOT decoration texture binding

If the context does not support the NPOTTextureRepeat (i.e. GL_OES_texture_npot extension), wrapping must be set to CLAMP_TO_EDGE to prevent invalid texture mapping.

Change-Id: I3ededccc14a32188986529c14fa91161fb383cfc
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Remove the QWidget compositor example

The QWidget API isn't well fit for a Wayland compositor, and does
not have any advantage over a QWindow, which can also draw using
QPainter. Besides the current implementation doesn't work properly,
and no one seems to be interested in fixing it.

Change-Id: Id1c337506af48e1d1fdd8d14f0ed637d299702f3
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
Add a note that qmake CONFIG+= only works in a clean tree

You need to use qmake -r on a tree which already has Makefiles. But you
probably need to clean up anyway in order to get the new functionality, so
this is a good recommendation for the general case.

Change-Id: Ie0fa10621a3fe961945da10a72e7fcc632f3fc0f
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>