Forked. Fix for menu popup bugs.

This commit is contained in:
2026-02-20 18:33:01 +01:00
parent d7de4ff112
commit 27f4b1dd38
3 changed files with 11 additions and 3 deletions

3
.gitignore vendored Normal file
View File

@@ -0,0 +1,3 @@
.env
xoat
xoat-debug

View File

@@ -1,6 +1,8 @@
xoat
====
Fork of [seanpringle](https://github.com/seanpringle)/[xoat](https://github.com/seanpringle/xoat)
*X Obstinate Asymmetric Tiler*
* Designed for wide screens, including multi-head support.

View File

@@ -102,7 +102,8 @@ void map_notify(XEvent *e)
{
client_raise_family(c);
client_update_border(c);
client_set_focus(c);
if (!c->menu) // Only set focus if it's not a menu/popup
client_set_focus(c);
client_free(a);
ewmh_client_list();
update_bars();
@@ -113,12 +114,14 @@ void map_notify(XEvent *e)
void unmap_notify(XEvent *e)
{
// if this window was focused, find something else
if (e->xunmap.window == current && !spot_focus_top_window(current_spot, current_mon, current))
Client *c = window_build_client(e->xunmap.window);
// if this window was focused, and it's not a menu/popup, find something else
if (c && !c->menu && e->xunmap.window == current && !spot_focus_top_window(current_spot, current_mon, current))
{
int i; for_spots(i)
if (spot_focus_top_window(i, current_mon, current)) break;
}
client_free(c);
ewmh_client_list();
update_bars();
menu_update();