Skip to content

Commit 70353da

Browse files
Marius Vladfooishbar
Marius Vlad
authored andcommitted
desktop-shell: Refuse to set a surface to maximized
For a surface that is already fullscreen making it maximized means to exit fullscreen then set to it maximized. Instead of doing it, refuse to do anything until the user explicitly performs that operation. With this approach we follow other DE (desktop environments) which would not perform any operation until the user exits fullscreen state. Fixes #321 Signed-off-by: Marius Vlad <[email protected]>
1 parent fed2ee5 commit 70353da

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

desktop-shell/shell.c

+3
Original file line numberDiff line numberDiff line change
@@ -2685,6 +2685,9 @@ set_maximized(struct shell_surface *shsurf, bool maximized)
26852685
weston_desktop_surface_get_surface(shsurf->desktop_surface);
26862686
int32_t width = 0, height = 0;
26872687

2688+
if (weston_desktop_surface_get_fullscreen(desktop_surface))
2689+
return;
2690+
26882691
if (maximized) {
26892692
struct weston_output *output;
26902693

0 commit comments

Comments
 (0)