shod

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README | LICENSE

commit 2d5a05226f23ace68c769a83140f3179ee469118
parent 5d4cbdee3f5b8862236e2dbaed27fd8bdc33d89c
Author: phillbush <phillbush@cock.li>
Date:   Tue, 14 Sep 2021 21:18:50 -0300

fix tryattach; fix containersendtodesk

Diffstat:
Mshod.c | 11++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)

diff --git a/shod.c b/shod.c @@ -2237,9 +2237,14 @@ containersendtodesk(struct Container *c, struct Desktop *desk, int place, int us return; c->desk = desk; c->mon = desk->mon; - if (place) { - containerplace(c, c->desk, userplaced); + if (c->issticky) { + c->issticky = 0; + ewmhsetstate(c); } + if (place) + containerplace(c, c->desk, userplaced); + if (desk != desk->mon->seldesk) /* container was sent to invisible desktop */ + containerhide(c, 1); containerraise(c); ewmhsetwmdesktop(c); } @@ -2937,7 +2942,7 @@ tryattach(struct Container *list, struct Tab *det, int xroot, int yroot) struct Tab *t, *next; for (c = list; c != NULL; c = c->rnext) { - if (xroot < c->x || xroot >= c->x + c->w || yroot < c->y || yroot >= c->y + c->h) + if (c->ishidden || xroot < c->x || xroot >= c->x + c->w || yroot < c->y || yroot >= c->y + c->h) continue; if (xroot - c->x < c->b + DROPPIXELS) { nrow = rownew();