From f149a8926d971f759b1faf2adf0b6bf242be1daa Mon Sep 17 00:00:00 2001 From: Jimmy Huang Date: Wed, 27 Feb 2013 15:59:50 -0800 Subject: [PATCH] Added handling for the new shell_surface_raise request in compositor Added implementation for raise request for the shell surface interface in wayland client protocol. It will call activate to raise the shell surface to the top of the window stack. Signed-off-by: Jimmy Huang --- src/shell.c | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/src/shell.c b/src/shell.c index d9b977e..2183ab4 100644 --- a/src/shell.c +++ b/src/shell.c @@ -38,6 +38,8 @@ #include "workspaces-server-protocol.h" #include "../shared/config-parser.h" +#define ENABLE_TIZEN + #define DEFAULT_NUM_WORKSPACES 1 #define DEFAULT_WORKSPACE_CHANGE_ANIMATION_LENGTH 200 @@ -1422,6 +1424,22 @@ shell_surface_set_class(struct wl_client *client, shsurf->class = strdup(class); } +#ifdef ENABLE_TIZEN +/* Extended to raise shell surface */ +static void +shell_surface_raise(struct wl_client *client, + struct wl_resource *resource) +{ + struct shell_surface *shsurf = resource->data; + struct weston_seat *seat; + struct weston_compositor *ec = shsurf->surface->compositor; + + wl_list_for_each(seat, &ec->seat_list, link) { + activate(shsurf->shell, shsurf->surface, seat); + } +} +#endif + static struct weston_output * get_default_output(struct weston_compositor *compositor) { @@ -1946,7 +1964,12 @@ static const struct wl_shell_surface_interface shell_surface_implementation = { shell_surface_set_popup, shell_surface_set_maximized, shell_surface_set_title, +#ifdef ENABLE_TIZEN + shell_surface_set_class, + shell_surface_raise // extended to raise app window +#else shell_surface_set_class +#endif` }; static void -- 2.7.4