[PATCH weston 2/2] libweston-desktop: fix unsetting fullscreen/maximize with wl_shell

Jonas Ã…dahl jadahl at gmail.com
Tue Sep 6 04:04:42 UTC 2016


On Sun, Sep 04, 2016 at 06:50:47PM +0300, Giulio Camuffo wrote:
> ---
>  libweston-desktop/wl-shell.c | 11 +++++++++++
>  1 file changed, 11 insertions(+)
> 
> diff --git a/libweston-desktop/wl-shell.c b/libweston-desktop/wl-shell.c
> index 74ce473..7172449 100644
> --- a/libweston-desktop/wl-shell.c
> +++ b/libweston-desktop/wl-shell.c
> @@ -151,6 +151,17 @@ weston_desktop_wl_shell_change_state(struct weston_desktop_wl_shell_surface *sur
>  
>  	assert(state != NONE);
>  
> +	if (surface->state != state) {
> +		if (surface->state == MAXIMIZED)
> +			weston_desktop_api_maximized_requested(surface->desktop,
> +								surface->surface,
> +								false);
> +		else if (surface->state == FULLSCREEN)
> +			weston_desktop_api_fullscreen_requested(surface->desktop,
> +								surface->surface,
> +								false, NULL);
> +	}
> +

Might as well move the calling with true here as well really.


Jonas

>  	if (to_add && surface->added) {
>  		surface->state = state;
>  		return;
> -- 
> 2.9.3
> 
> _______________________________________________
> wayland-devel mailing list
> wayland-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/wayland-devel


More information about the wayland-devel mailing list