aboutsummaryrefslogtreecommitdiffstats
path: root/XMonad/Prompt
diff options
context:
space:
mode:
authorDevin Mullins <me@twifkak.com>2008-08-11 05:31:37 +0200
committerDevin Mullins <me@twifkak.com>2008-08-11 05:31:37 +0200
commit25b84d6386701c79e6fb389c1d0ce843a48f0243 (patch)
treefc348c4409b7ea477d1ef22a8a706a412017918b /XMonad/Prompt
parent0a4c3ab0a241f4fa1fc7b6166988e6816b8e58e6 (diff)
downloadXMonadContrib-25b84d6386701c79e6fb389c1d0ce843a48f0243.tar.gz
XMonadContrib-25b84d6386701c79e6fb389c1d0ce843a48f0243.tar.xz
XMonadContrib-25b84d6386701c79e6fb389c1d0ce843a48f0243.zip
simplify WindowBringer code, and change greedyView to focusWindow
darcs-hash:20080811033137-78224-6fb0ea21833cf4400fce90981b07826d26162451.gz
Diffstat (limited to 'XMonad/Prompt')
-rw-r--r--XMonad/Prompt/Window.hs10
1 files changed, 4 insertions, 6 deletions
diff --git a/XMonad/Prompt/Window.hs b/XMonad/Prompt/Window.hs
index 65d4009..c45417e 100644
--- a/XMonad/Prompt/Window.hs
+++ b/XMonad/Prompt/Window.hs
@@ -73,16 +73,14 @@ windowPromptBring c = doPrompt Bring c
doPrompt :: WindowPrompt -> XPConfig -> X ()
doPrompt t c = do
a <- case t of
- Goto -> return . gotoAction =<< windowMapWith (W.tag . fst)
- Bring -> return . bringAction =<< windowMapWith snd
- wm <- windowMapWith id
+ Goto -> fmap gotoAction windowMap
+ Bring -> fmap bringAction windowMap
+ wm <- windowMap
mkXPrompt t c (compList wm) a
where
-
winAction a m = flip whenJust (windows . a) . flip M.lookup m
- gotoAction = winAction W.greedyView
+ gotoAction = winAction W.focusWindow
bringAction = winAction bringWindow
- bringWindow w ws = W.shiftWin (W.tag . W.workspace . W.current $ ws) w ws
compList m s = return . filter (isPrefixOf s) . map fst . M.toList $ m