about summary refs log tree commit diff
path: root/exwm.el
diff options
context:
space:
mode:
Diffstat (limited to 'exwm.el')
-rw-r--r--exwm.el7
1 files changed, 3 insertions, 4 deletions
diff --git a/exwm.el b/exwm.el
index 4a6e9fd5d2ac..9151fdc5c38c 100644
--- a/exwm.el
+++ b/exwm.el
@@ -438,10 +438,9 @@
             ;; FIXME: check (may require other properties set)
             (when (memq xcb:Atom:_NET_WM_STATE_DEMANDS_ATTENTION props)
               (when (= action xcb:ewmh:_NET_WM_STATE_ADD)
-                (let ((idx (exwm-workspace--position exwm--frame)))
-                  (unless (= idx exwm-workspace-current-index)
-                    (set-frame-parameter exwm--frame 'exwm--urgency t)
-                    (setq exwm-workspace--switch-history-outdated t))))
+                (unless (eq exwm--frame exwm-workspace--current)
+                  (set-frame-parameter exwm--frame 'exwm--urgency t)
+                  (setq exwm-workspace--switch-history-outdated t)))
               ;; xcb:ewmh:_NET_WM_STATE_REMOVE?
               ;; xcb:ewmh:_NET_WM_STATE_TOGGLE?
               )