rpi: Support opaque regions

This is needed for XWayland surfaces with alpha channel, as X will be
sending crap in there that should be discarded.

This is currently done with a copy in the compositor, while we wait for
support in the VideoCore side.
src/shell.c: set black_surface->width and height

full screen black_surface doesn't have associated wl_buffer, so
black_surface->width and height can't get value through
weston_surface_commit(). then weston_surface_damage(black_surface)
will be wrong in shell_stack_fullscreen(), the result is that we
can't see a full screen view whe APP window's size isn't equal to
output's size like running weston-gears

Signed-off-by: Xiong Zhang <xiong.y.zhang@intel.com>
shell: Reorganise set/unset methods for fullscreen/maximize/popup/transient

Move them to be next to each other, and standardise the naming scheme so
they’re more greppable. This should make maintenance easier.
shell: Add missing cases to switch statements for surface types

This fixes a load of GCC warnings when compiling with -Wswitch-enum
-Wswitch-default, and makes it clearer that those cases have been
thought about explicitly when writing the code, rather than just being
forgotten.
shell: Add missing cases to switch statements for animations and fading

This fixes two GCC warnings when compiling with -Wswitch-enum
-Wswitch-default, and makes it clearer that those cases have been
thought about explicitly when writing the code, rather than just being
forgotten.
clients: Add window_is_transient() helper to the toy toolkit window
clients: Add a new weston-stacking demo

This allows creation of a variety of window types, for the purposes of
testing window ordering and stacking in Weston.
shell: Factor out common code to set a shsurf’s output
shell: Refactor workspace code to operate on shsurfs rather than views

This is needed for the work to refactor window stacking and ordering, as
window order operates on shsurfs, not views.
shell: Tidy up unset_fullscreen()

No functional changes, merely some presentational cleanup.
shell: Factor out code to set a shsurf’s parent

This is in preparation for unifying how surface layering works. It
introduces the small functional change that fullscreen, maximized and
top-level surfaces now explicitly have no parent surface. Only popup and
transient surfaces have a non-NULL parent.
shell: Don’t change popups’ window types until the next configure event

This standardises their behaviour with that of the other window types,
where the type change is only committed on configure.
shell: Factor out code to set the layer for a shsurf

This will be used more extensively in the next few commits, where shsurf
layering is handled more explicitly when changing the type of a surface.

This commit introduces the minor functional change that map() will now
always add the new surface to a layer list, as
shell_surface_calculate_layer_link() always returns a non-NULL link
element. This affects fullscreen and ‘none’ surfaces (which are now added
to the fullscreen and current workspace’s layer list, respectively).
shell: Update a shsurf’s layer when its surface type changes
shell: Remove weston_view_restack()

It’s tied too deeply into the shell’s window stacking and ordering code
to legitimately be split out into compositor.c. Inline it in the shell,
and refactor some code around it a little, tidying up the stacking
behaviour for fullscreen surfaces.
shell: Factor out common code to create fullscreen black surfaces
shell: Store parent–child links between shsurfs for window stacking

This ensures transient surfaces are included in the layer of their
parent, even if the parent later changes layers. It achieves this by
recursively changing the layers of all children of a surface when that
surface’s layer is changed. The recursion is unbounded unless transient
surfaces are restricted to not being children of other popup or transient
surfaces.

This fixes a bug whereby a surface which is transient for a fullscreen
surface could end up being stacked below it.

https://bugs.freedesktop.org/show_bug.cgi?id=69443
shell: Fix a potential NULL pointer dereference

get_shell_surface() may return NULL. Found by scan-build.
shell: Change stacking order calculation for popup surfaces

Always put them as the top-most layer in the layer list of their parent.
This ensures that, for example, the popup menu produced by
right-clicking on a surface (which is not currently at the top of the
stacking order in the current workspace) is displayed at the top of the
stacking order.
rpi: Use common udev_input for input device handling

The purpose of this patch is to move away from separating evdev
functionality from udev functionality in order to rely on a separate
library to do this for us.

This patch is only compile tested and I have no idea how much it breaks.

Signed-off-by: Jonas Ådahl <jadahl@gmail.com>