From 20c0650dfdfb64c17499e04665f491a6871d4917 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Ekl=C3=B6f?= Date: Thu, 24 Jun 2021 23:02:40 +0200 Subject: [PATCH] =?UTF-8?q?wayland:=20regression:=20properly=20instantiate?= =?UTF-8?q?=20CSDs=20when=20there=E2=80=99s=20no=20decoration=20manager?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Set win->configure.csd_mode, not win->csd_mode. Otherwise our ‘configure’ handler will swap out the CSD_YES we set, for CSD_UNKNOWN(?), resulting in no CSDs at all. * Don’t instantiate the CSDs in wayl_win_init(), let the ‘configure’ event handler do that. Just like it does when we have a decoration manager emitting decoration configure events. --- wayland.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/wayland.c b/wayland.c index 301760d8..80fef88a 100644 --- a/wayland.c +++ b/wayland.c @@ -1384,8 +1384,7 @@ wayl_win_init(struct terminal *term) win->xdg_toplevel_decoration, &xdg_toplevel_decoration_listener, win); } else { /* No decoration manager - thus we *must* draw our own decorations */ - win->csd_mode = CSD_YES; - csd_instantiate(win); + win->configure.csd_mode = CSD_YES; LOG_WARN("no decoration manager available - using CSDs unconditionally"); }