From 53b5c60a5e8bbf2942ef174c2db64db6cdac3e26 Mon Sep 17 00:00:00 2001 From: Dana Jansens Date: Fri, 14 Feb 2003 18:31:52 +0000 Subject: [PATCH] check if the window is focused before unfocusing it --- src/screen.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/screen.cc b/src/screen.cc index 17a8c225..3f507afb 100644 --- a/src/screen.cc +++ b/src/screen.cc @@ -669,7 +669,7 @@ void Screen::unmanageWindow(Client *client) client->_modal = false; // unfocus the client (calls the focus callbacks) - client->unfocus(); + if (client->focused()) client->unfocus(); #ifdef DEBUG printf("Unmanaged window 0x%lx frame 0x%lx\n", client->window(), framewin); -- 2.39.2