[PATCH weston 2/2] desktop-shell: unfullscreen before (un)maximizing
pochu27 at gmail.com
pochu27 at gmail.com
Wed Jan 29 02:11:13 PST 2014
From: Emilio Pozuelo Monfort <emilio.pozuelo at collabora.co.uk>
Before maximizing or unmaximizing a window, first tell the
client to unfullscreen the window. This fixes a crash in weston
because we ended up thinking the surface was fullscreened when
it wasn't.
---
desktop-shell/shell.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/desktop-shell/shell.c b/desktop-shell/shell.c
index 7d85a7b..30bd273 100644
--- a/desktop-shell/shell.c
+++ b/desktop-shell/shell.c
@@ -3845,6 +3845,10 @@ maximize_binding(struct weston_seat *seat, uint32_t time, uint32_t button, void
if (!shell_surface_is_xdg_surface(shsurf))
return;
+ /* First un-fullscreen if needed */
+ if (shsurf->state.fullscreen)
+ xdg_surface_send_request_unset_fullscreen(shsurf->resource);
+
if (shsurf->state.maximized)
xdg_surface_send_request_unset_maximized(shsurf->resource);
else
--
1.8.5.3
More information about the wayland-devel
mailing list