From bce6c0498e7406abaa33b0f28c22457a0e87ddc3 Mon Sep 17 00:00:00 2001 From: DreamMaoMao <2523610504@qq.com> Date: Fri, 19 Dec 2025 14:35:43 +0800 Subject: [PATCH] fix: inhibit_regardless_of_visibility not apply in some case --- src/mango.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/mango.c b/src/mango.c index c96126f..c538303 100644 --- a/src/mango.c +++ b/src/mango.c @@ -2001,23 +2001,26 @@ buttonpress(struct wl_listener *listener, void *data) { void checkidleinhibitor(struct wlr_surface *exclude) { int inhibited = 0; + Client *c = NULL; + struct wlr_surface *surface = NULL; struct wlr_idle_inhibitor_v1 *inhibitor; wl_list_for_each(inhibitor, &idle_inhibit_mgr->inhibitors, link) { - struct wlr_surface *surface = - wlr_surface_get_root_surface(inhibitor->surface); + surface = wlr_surface_get_root_surface(inhibitor->surface); if (exclude == surface) { continue; } + toplevel_from_wlr_surface(inhibitor->surface, &c, NULL); + if (inhibit_regardless_of_visibility) { inhibited = 1; break; } struct wlr_scene_tree *tree = surface->data; - if (!tree || tree->node.enabled) { + if (!tree || (tree->node.enabled && (!c || !c->animation.tagouting))) { inhibited = 1; break; }