summaryrefslogtreecommitdiff
path: root/mcwm.c
diff options
context:
space:
mode:
authorMC <mc@hack.org>2010-06-23 22:07:22 +0200
committerMC <mc@hack.org>2010-06-23 22:07:22 +0200
commit303f943bd7cd696e84e9e4c7369bff3b8d5c9759 (patch)
treefd0bfb386e112951871d1705593c7b8184b43fbf /mcwm.c
parent34be9f9e245480a2d35c88c4f26c048c6e53b0ab (diff)
downloadmcwm-303f943bd7cd696e84e9e4c7369bff3b8d5c9759.zip
We need both normal and ungrab enter notify events.
Diffstat (limited to 'mcwm.c')
-rw-r--r--mcwm.c23
1 files changed, 11 insertions, 12 deletions
diff --git a/mcwm.c b/mcwm.c
index 72a2eec..4c39ec4 100644
--- a/mcwm.c
+++ b/mcwm.c
@@ -1312,22 +1312,21 @@ void events(void)
* focus in these cases.
*
*/
- if (e->mode != XCB_NOTIFY_MODE_NORMAL)
+ if (e->mode == XCB_NOTIFY_MODE_NORMAL
+ || e->mode == XCB_NOTIFY_MODE_UNGRAB)
{
- PDEBUG("Not a normal EnterNotify. Ignoring.\n");
- break;
- }
- /*
- * If we're entering the same window we focus now,
- * then don't bother focusing.
- */
- if (e->event != focuswin)
- {
/*
- * Otherwise, set focus to the window we just entered.
+ * If we're entering the same window we focus now,
+ * then don't bother focusing.
*/
- setfocus(e->event);
+ if (e->event != focuswin)
+ {
+ /*
+ * Otherwise, set focus to the window we just entered.
+ */
+ setfocus(e->event);
+ }
}
}
break;