summaryrefslogtreecommitdiffhomepage
path: root/src/Plugins
diff options
context:
space:
mode:
authorBen Boeckel <mathstuf@gmail.com>2011-12-05 19:13:46 -0500
committerBen Boeckel <mathstuf@gmail.com>2012-03-11 13:50:24 -0400
commitc0e28d9812633ec1734cd3be9832456260f04ea6 (patch)
tree10215384ce1ebdb89932cc311fd47b4e02e48e62 /src/Plugins
parentbaca50387a262e3476e94029232258e0d4591d27 (diff)
downloadxmobar-c0e28d9812633ec1734cd3be9832456260f04ea6.tar.gz
xmobar-c0e28d9812633ec1734cd3be9832456260f04ea6.tar.bz2
Allow XMonadLog to have a separate name as well
Diffstat (limited to 'src/Plugins')
-rw-r--r--src/Plugins/XMonadLog.hs8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/Plugins/XMonadLog.hs b/src/Plugins/XMonadLog.hs
index 3461e26..1403800 100644
--- a/src/Plugins/XMonadLog.hs
+++ b/src/Plugins/XMonadLog.hs
@@ -30,17 +30,19 @@ import Foreign.C (CChar)
import XUtil (nextEvent')
-data XMonadLog = XMonadLog | XPropertyLog String
+data XMonadLog = XMonadLog | XPropertyLog String | NamedXPropertyLog String String
deriving (Read, Show)
instance Exec XMonadLog where
alias XMonadLog = "XMonadLog"
alias (XPropertyLog atom) = atom
+ alias (NamedXPropertyLog _ name) = name
start x cb = do
let atom = case x of
- XMonadLog -> "_XMONAD_LOG"
- XPropertyLog a -> a
+ XMonadLog -> "_XMONAD_LOG"
+ XPropertyLog a -> a
+ NamedXPropertyLog a _ -> a
d <- openDisplay ""
xlog <- internAtom d atom False