From 284014801add553b29065ec7f9592b7fe1d02670 Mon Sep 17 00:00:00 2001 From: Brent Yorgey Date: Wed, 3 Jun 2015 16:20:27 +0200 Subject: X.A.WorkspaceNames: convert tabs to spaces, cleanup Ignore-this: 25bf16b21dcfcd1b6e848241217656a4 darcs-hash:20150603142027-bd4d7-9b7cbfa99a5ed6b4121de959e420ef4996b4f52b.gz --- XMonad/Actions/WorkspaceNames.hs | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'XMonad') diff --git a/XMonad/Actions/WorkspaceNames.hs b/XMonad/Actions/WorkspaceNames.hs index 16661c0..fbea92e 100644 --- a/XMonad/Actions/WorkspaceNames.hs +++ b/XMonad/Actions/WorkspaceNames.hs @@ -158,14 +158,14 @@ swapNames w1 w2 = do -- | Same behavior than 'XMonad.Prompt.Workspace.workspacePrompt' excepted it acts on the workspace name provided by this module. workspaceNamePrompt :: XPConfig -> (String -> X ()) -> X () workspaceNamePrompt conf job = do - myWorkspaces <- gets $ map W.tag . W.workspaces . windowset - myWorkspacesName <- getWorkspaceNames >>= \f -> return $ map f myWorkspaces - let pairs = zip myWorkspacesName myWorkspaces - mkXPrompt (Wor "Select workspace: ") conf - (contains myWorkspacesName) - (job . toWsId pairs) - where toWsId pairs name = case lookup name pairs of + myWorkspaces <- gets $ map W.tag . W.workspaces . windowset + myWorkspacesName <- getWorkspaceNames >>= \f -> return $ map f myWorkspaces + let pairs = zip myWorkspacesName myWorkspaces + mkXPrompt (Wor "Select workspace: ") conf + (contains myWorkspacesName) + (job . toWsId pairs) + where toWsId pairs name = case lookup name pairs of Nothing -> "" - Just i -> i - contains completions input = - return $ filter (Data.List.isInfixOf input) completions + Just i -> i + contains completions input = + return $ filter (Data.List.isInfixOf input) completions -- cgit v1.2.3