diff options
| author | Dana Jansens <danakj@orodu.net> | 2007-04-26 06:10:13 +0000 |
|---|---|---|
| committer | Dana Jansens <danakj@orodu.net> | 2007-04-26 06:10:13 +0000 |
| commit | b673823d0b6dfdde1031dfed4f42544921f3c984 (patch) | |
| tree | 24d27da63fba6b63d641b3b6f02ca09371979b8f /openbox | |
| parent | bdf287572cc2d81330fb82e3ccaff37f43389720 (diff) | |
have to fallback in client_unmanage, until we figure out a way to hear those focusin events without conflicting screens
Diffstat (limited to 'openbox')
| -rw-r--r-- | openbox/client.c | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/openbox/client.c b/openbox/client.c index 84f739ac..7fcc0668 100644 --- a/openbox/client.c +++ b/openbox/client.c @@ -493,9 +493,22 @@ void client_unmanage(ObClient *self) /* update the focus lists */ focus_order_remove(self); - /* don't leave an invalid focus_client */ - if (self == focus_client) + if (self == focus_client) { + /* we have to fall back here because we might not get a focus out. + 1. we need to xselectinput off the window before we unmap it because + otherwise we end up getting unmapnotifies we don't want and they + can mess up mapping it again quickly + 2. this means that if we unmanage from a synthetic unmapnotify, we + are the ones unmapped it, and causing the focusout. so we won't + get the focusout event. + 3. we can't handle focusin events on the root window because they + come from all screens, so the focus change gets lost + */ + focus_fallback(FALSE); + + /* don't leave an invalid focus_client */ focus_client = NULL; + } client_list = g_list_remove(client_list, self); stacking_remove(self); |
