diff options
| -rw-r--r-- | monsterwm.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/monsterwm.c b/monsterwm.c index 82efdea..ca29548 100644 --- a/monsterwm.c +++ b/monsterwm.c @@ -833,14 +833,17 @@ void update_current(client *c) { if (!(current = c)) { XDeleteProperty(dis, root, netatoms[NET_ACTIVE]); return; } XWindowChanges wc; - if (!c->isfloating && !c->istransient) for (wc.sibling = c->win, c=head; c; c=c->next) { + if (current->isfloating || current->istransient) { + XSetWindowBorderWidth(dis, current->win, BORDER_WIDTH); + XRaiseWindow(dis, current->win); + } else for (wc.sibling = current->win, c=head; c; c=c->next) { XSetWindowBorderWidth(dis, c->win, (!head->next || c->isfullscrn || (mode==MONOCLE && !ISFFT(c))) ? 0:BORDER_WIDTH); wc.stack_mode = (c->isfloating || c->istransient) ? Above:Below; XConfigureWindow(dis, c->win, CWSibling|CWStackMode, &wc); if (CLICK_TO_FOCUS) XGrabButton(dis, Button1, None, c->win, True, ButtonPressMask, GrabModeAsync, GrabModeAsync, None, None); - } else XRaiseWindow(dis, current->win); + } tile(); XSetWindowBorder(dis, current->win, win_focus); |
