diff options
author | Devin Mullins <me@twifkak.com> | 2007-11-11 01:26:17 +0100 |
---|---|---|
committer | Devin Mullins <me@twifkak.com> | 2007-11-11 01:26:17 +0100 |
commit | 49d099aba3fae63101ec4e017e68bae5c8d66771 (patch) | |
tree | 2bf5933cc58b4ec2a173c8034ec3fb8b44fbf81c | |
parent | d19e81b88ca496364ef4be00e1fe72b4ff5f547b (diff) | |
download | XMonadContrib-49d099aba3fae63101ec4e017e68bae5c8d66771.tar.gz XMonadContrib-49d099aba3fae63101ec4e017e68bae5c8d66771.tar.xz XMonadContrib-49d099aba3fae63101ec4e017e68bae5c8d66771.zip |
wrap user code in userCode, go figure
(thanks à shachaf for that suggestion)
darcs-hash:20071111002617-78224-7920bc75560383513979d9e550025eb6a19654fb.gz
Diffstat (limited to '')
-rw-r--r-- | XMonad/Hooks/UrgencyHook.hs | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/XMonad/Hooks/UrgencyHook.hs b/XMonad/Hooks/UrgencyHook.hs index 4956079..84a7628 100644 --- a/XMonad/Hooks/UrgencyHook.hs +++ b/XMonad/Hooks/UrgencyHook.hs @@ -98,7 +98,7 @@ instance UrgencyHook h Window => LayoutModifier (WithUrgencyHook h) Window where when (t == propertyNotify && a == wM_HINTS) $ withDisplay $ \dpy -> do wmh@WMHints { wmh_flags = flags } <- io $ getWMHints dpy w when (testBit flags urgencyHintBit) $ do - urgencyHook theHook w + userCode $ urgencyHook theHook w -- Clear the urgency bit in the WMHints flags field. According to the -- Xlib manual, the *client* is supposed to clear this flag when the urgency -- has been resolved, but, Xchat2, for example, sets the WMHints several @@ -107,8 +107,7 @@ instance UrgencyHook h Window => LayoutModifier (WithUrgencyHook h) Window where io $ setWMHints dpy w wmh { wmh_flags = clearBit flags urgencyHintBit } adjustUrgents (\ws -> if elem w ws then ws else w : ws) -- Call logHook after IORef has been modified. - theLogHook <- asks (logHook . config) - theLogHook + userCode =<< asks (logHook . config) -- Doing the setWMHints triggers another propertyNotify with the bit -- cleared, so we ignore that message. This has the potentially wrong -- effect of ignoring *all* urgency-clearing messages, some of which might |