diff options
author | Leonardo Hernández Hernández <leohdz172@proton.me> | 2023-11-01 12:04:59 -0600 |
---|---|---|
committer | Leonardo Hernández Hernández <leohdz172@proton.me> | 2023-11-01 12:04:59 -0600 |
commit | e5e74acfce05502181a0eaa6e252140e1572d925 (patch) | |
tree | da35c22a40815ab2559f759b5f66a046a3281869 | |
parent | 892a4d3ec73406900201cba71bbe33895cdfaf35 (diff) |
send maximized if tiled isn't supported (XDG shell)
wlroots doesn't do it automatically anymore
References: https://gitlab.freedesktop.org/wlroots/wlroots/-/merge_requests/4409
-rw-r--r-- | client.h | 7 |
1 files changed, 6 insertions, 1 deletions
@@ -354,7 +354,12 @@ client_set_tiled(Client *c, uint32_t edges) if (client_is_x11(c)) return; #endif - wlr_xdg_toplevel_set_tiled(c->surface.xdg->toplevel, edges); + if (wl_resource_get_version(c->surface.xdg->resource) + >= XDG_TOPLEVEL_STATE_TILED_RIGHT_SINCE_VERSION) { + wlr_xdg_toplevel_set_tiled(c->surface.xdg->toplevel, edges); + } else { + wlr_xdg_toplevel_set_maximized(c->surface.xdg->toplevel, edges != 0); + } } static inline void |