From 5dfc01095a11cc14d15b5cb736f9425f73142fa0 Mon Sep 17 00:00:00 2001 From: Bastien Dejean Date: Tue, 25 Dec 2012 12:39:23 +0100 Subject: [PATCH] Only the current window shall not become urgent We should only discard the urgency state of the focused window of the focused desktop of the focused monitor. --- events.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/events.c b/events.c index 4a488c2..b79eb61 100644 --- a/events.c +++ b/events.c @@ -188,13 +188,14 @@ void property_notify(xcb_generic_event_t *evt) window_location_t loc; if (locate_window(e->window, &loc)) { - if (loc.node == loc.desktop->focus) - return; if (xcb_icccm_get_wm_hints_reply(dpy, xcb_icccm_get_wm_hints(dpy, e->window), &hints, NULL) == 1) { - loc.node->client->urgent = (hints.flags & XCB_ICCCM_WM_HINT_X_URGENCY); - put_status(); - if (loc.monitor->desk == loc.desktop) - arrange(loc.monitor, loc.desktop); + uint32_t urgent = xcb_icccm_wm_hints_get_urgency(&hints); + if (urgent != 0 && loc.node != mon->desk->focus) { + loc.node->client->urgent = urgent; + put_status(); + if (loc.monitor->desk == loc.desktop) + arrange(loc.monitor, loc.desktop); + } } } } -- 2.44.0