From 4928ca5a90eb7520ae622970b10f73c99955387f Mon Sep 17 00:00:00 2001 From: Rob Bradford Date: Thu, 8 Dec 2011 16:19:50 +0000 Subject: [PATCH] wayland: Port to latest Wayland API (to wl_surface_shell) Requests for the shell to manipulate it's state for the surface are now abstracted through a wl_shell_surface object rather through wl_shell as before. Reviewed-by: Robert Bragg --- cogl/winsys/cogl-winsys-egl.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/cogl/winsys/cogl-winsys-egl.c b/cogl/winsys/cogl-winsys-egl.c index 7fc3268ea..abf7d23af 100644 --- a/cogl/winsys/cogl-winsys-egl.c +++ b/cogl/winsys/cogl-winsys-egl.c @@ -99,6 +99,7 @@ typedef struct _CoglOnscreenEGL #ifdef COGL_HAS_EGL_PLATFORM_WAYLAND_SUPPORT struct wl_egl_window *wayland_egl_native_window; struct wl_surface *wayland_surface; + struct wl_shell_surface *wayland_shell_surface; #endif #ifdef COGL_HAS_EGL_PLATFORM_KMS_SUPPORT @@ -1332,6 +1333,10 @@ _cogl_winsys_onscreen_init (CoglOnscreen *onscreen, return FALSE; } + egl_onscreen->wayland_shell_surface = + wl_shell_get_shell_surface (egl_renderer->wayland_shell, + egl_onscreen->wayland_surface); + egl_onscreen->wayland_egl_native_window = wl_egl_window_create (egl_onscreen->wayland_surface, cogl_framebuffer_get_width (framebuffer), @@ -1352,8 +1357,7 @@ _cogl_winsys_onscreen_init (CoglOnscreen *onscreen, egl_onscreen->wayland_egl_native_window, NULL); - wl_shell_set_toplevel (egl_renderer->wayland_shell, - egl_onscreen->wayland_surface); + wl_shell_surface_set_toplevel (egl_onscreen->wayland_shell_surface); #elif defined (COGL_HAS_EGL_PLATFORM_POWERVR_NULL_SUPPORT) || \ defined (COGL_HAS_EGL_PLATFORM_ANDROID_SUPPORT) || \