Got questions, comments, patches, etc.?
Contact Jason Woofenden
gitweb
/
spectrwm.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Make sure we unmange windows in non active workspaces; this sometimes
[spectrwm.git]
/
scrotwm.c
diff --git
a/scrotwm.c
b/scrotwm.c
index
da2a944
..
a49a433
100644
(file)
--- a/
scrotwm.c
+++ b/
scrotwm.c
@@
-3165,10
+3165,7
@@
unmanage_window(struct ws_win *win)
DNPRINTF(SWM_D_MISC, "unmanage_window: %lu\n", win->id);
DNPRINTF(SWM_D_MISC, "unmanage_window: %lu\n", win->id);
- /* don't unmanage if we are switching workspaces */
ws = win->ws;
ws = win->ws;
- if (ws->restack)
- return;
/* find a window to focus */
if (ws->focus == win)
/* find a window to focus */
if (ws->focus == win)
@@
-3312,23
+3309,22
@@
focusin(XEvent *e)
void
focusout(XEvent *e)
{
void
focusout(XEvent *e)
{
+ struct swm_screen *s;
+ Window rr, cr;
+ int x, y, wx, wy;
+ unsigned int mask;
+
DNPRINTF(SWM_D_EVENT, "focusout: window: %lu\n", e->xfocus.window);
if (cur_focus && cur_focus->ws->r &&
cur_focus->id == e->xfocus.window) {
DNPRINTF(SWM_D_EVENT, "focusout: window: %lu\n", e->xfocus.window);
if (cur_focus && cur_focus->ws->r &&
cur_focus->id == e->xfocus.window) {
- struct swm_screen *s = cur_focus->ws->r->s;
- Window rr, cr;
- int x, y, wx, wy;
- unsigned int mask;
-
- /* Try to detect synergy hiding the cursor. */
+ s = cur_focus->ws->r->s;
if (XQueryPointer(display, cur_focus->id,
&rr, &cr, &x, &y, &wx, &wy, &mask) != False &&
cr == 0 && !mask &&
if (XQueryPointer(display, cur_focus->id,
&rr, &cr, &x, &y, &wx, &wy, &mask) != False &&
cr == 0 && !mask &&
- x == DisplayWidth(display, s->idx)/2 &&
- y == DisplayHeight(display, s->idx)/2) {
+ x == DisplayWidth(display, s->idx) / 2 &&
+ y == DisplayHeight(display, s->idx) / 2)
unfocus_win(cur_focus);
unfocus_win(cur_focus);
- }
}
}
}
}