diff --git a/event.c b/event.c index 1917f6535..bda0cc5a2 100644 --- a/event.c +++ b/event.c @@ -677,9 +677,11 @@ event_handle_unmapnotify(void *data __attribute__ ((unused)), if((c = client_getbywin(ev->window))) { if(ev->event == xutil_screen_get(connection, c->phys_screen)->root - && XCB_EVENT_SENT(ev) - && window_state_get_reply(window_state_get_unchecked(c->window)) == XCB_WM_STATE_NORMAL) + && XCB_EVENT_SENT(ev)) + { client_unmanage(c); + xcb_unmap_window(connection, ev->window); + } } else for(int i = 0; i < globalconf.embedded.len; i++)