[PATCH weston] clients: Set title for all shell surface demos.

Kristian Høgsberg hoegsberg at gmail.com
Tue Oct 9 20:13:15 PDT 2012


On Sun, Oct 07, 2012 at 08:56:30AM -0600, Scott Moreau wrote:

That makes sense, thanks.

Kristian

> ---
>  clients/flower.c       | 1 +
>  clients/simple-egl.c   | 2 ++
>  clients/simple-shm.c   | 2 ++
>  clients/simple-touch.c | 1 +
>  4 files changed, 6 insertions(+)
> 
> diff --git a/clients/flower.c b/clients/flower.c
> index a403234..dac52d5 100644
> --- a/clients/flower.c
> +++ b/clients/flower.c
> @@ -180,6 +180,7 @@ int main(int argc, char *argv[])
>  	flower.display = d;
>  	flower.window = window_create(d);
>  	flower.widget = window_add_widget(flower.window, &flower);
> +	window_set_title(flower.window, "Flower");
>  
>  	widget_set_resize_handler(flower.widget, resize_handler);
>  	widget_set_redraw_handler(flower.widget, redraw_handler);
> diff --git a/clients/simple-egl.c b/clients/simple-egl.c
> index a67ce2f..d6842af 100644
> --- a/clients/simple-egl.c
> +++ b/clients/simple-egl.c
> @@ -317,6 +317,8 @@ create_surface(struct window *window)
>  				       display->egl.conf,
>  				       window->native, NULL);
>  
> +	wl_shell_surface_set_title(window->shell_surface, "simple-egl");
> +
>  	ret = eglMakeCurrent(window->display->egl.dpy, window->egl_surface,
>  			     window->egl_surface, window->display->egl.ctx);
>  	assert(ret == EGL_TRUE);
> diff --git a/clients/simple-shm.c b/clients/simple-shm.c
> index d0aeeb2..f62e54e 100644
> --- a/clients/simple-shm.c
> +++ b/clients/simple-shm.c
> @@ -142,6 +142,8 @@ create_window(struct display *display, int width, int height)
>  		wl_shell_surface_add_listener(window->shell_surface,
>  					      &shell_surface_listener, window);
>  
> +	wl_shell_surface_set_title(window->shell_surface, "simple-shm");
> +
>  	wl_shell_surface_set_toplevel(window->shell_surface);
>  
>  	return window;
> diff --git a/clients/simple-touch.c b/clients/simple-touch.c
> index 6087fe4..03fd45b 100644
> --- a/clients/simple-touch.c
> +++ b/clients/simple-touch.c
> @@ -301,6 +301,7 @@ touch_create(int width, int height)
>  	}
>  
>  	wl_surface_set_user_data(touch->surface, touch);
> +	wl_shell_surface_set_title(touch->shell_surface, "simple-touch");
>  
>  	memset(touch->data, 64, width * height * 4);
>  	wl_surface_attach(touch->surface, touch->buffer, 0, 0);
> -- 
> 1.7.11.4
> 
> _______________________________________________
> wayland-devel mailing list
> wayland-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/wayland-devel


More information about the wayland-devel mailing list