summaryrefslogtreecommitdiff
path: root/libweston-desktop
diff options
context:
space:
mode:
authorQuentin Glidic <sardemff7+git@sardemff7.net>2016-12-17 13:40:51 +0100
committerPekka Paalanen <pekka.paalanen@collabora.co.uk>2017-01-17 16:50:18 +0200
commit82681571cf2407ed61bd1d29065583ddd4c2e525 (patch)
tree876f2e1d8b2094424c513d93490e11ed444dc462 /libweston-desktop
parent39d7e99a461dc43385381d465891bdcfbb67be5c (diff)
libweston: Position layers in an absolute way
Currently, layers’ order depends on the module loading order and it does not survive runtime modifications (like shell locking/unlocking). With this patch, modules can safely add their own layer at the expected position in the stack, with runtime persistence. v4 Reviewed-by: Giulio Camuffo <giuliocamuffo@gmail.com> Signed-off-by: Quentin Glidic <sardemff7+git@sardemff7.net> Acked-by: Daniel Stone <daniels@collabora.com> [Pekka: fix three whitespace issues] Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Diffstat (limited to 'libweston-desktop')
-rw-r--r--libweston-desktop/xwayland.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/libweston-desktop/xwayland.c b/libweston-desktop/xwayland.c
index 663734a8..1b19e224 100644
--- a/libweston-desktop/xwayland.c
+++ b/libweston-desktop/xwayland.c
@@ -386,7 +386,11 @@ weston_desktop_xwayland_init(struct weston_desktop *desktop)
xwayland->desktop = desktop;
xwayland->client = weston_desktop_client_create(desktop, NULL, NULL, NULL, NULL, 0, 0);
- weston_layer_init(&xwayland->layer, &compositor->cursor_layer.link);
+ weston_layer_init(&xwayland->layer, compositor);
+ /* We put this layer on top of regular shell surfaces, but hopefully
+ * below any UI the shell would add */
+ weston_layer_set_position(&xwayland->layer,
+ WESTON_LAYER_POSITION_NORMAL + 1);
compositor->xwayland = xwayland;
compositor->xwayland_interface = &weston_desktop_xwayland_interface;