aboutsummaryrefslogtreecommitdiffstats
path: root/Operations.hs
diff options
context:
space:
mode:
authorglasser <glasser@mit.edu>2007-06-01 02:13:25 +0200
committerglasser <glasser@mit.edu>2007-06-01 02:13:25 +0200
commitca38ba759d3b53fddfb1073db4e1c1fbf4ed493a (patch)
tree4e5a2db52a1321a21cba06ebd5eb1bd22a1d4acd /Operations.hs
parent2c5abb6201197e176a873c1601d8ba6c3b791601 (diff)
downloadxmonad-ca38ba759d3b53fddfb1073db4e1c1fbf4ed493a.tar.gz
xmonad-ca38ba759d3b53fddfb1073db4e1c1fbf4ed493a.tar.xz
xmonad-ca38ba759d3b53fddfb1073db4e1c1fbf4ed493a.zip
Rename withWorkspace to withWindowSet.
darcs-hash:20070601001325-64353-3ea08019b13ac470d7d2c60cbdea61de7d580c8c.gz
Diffstat (limited to 'Operations.hs')
-rw-r--r--Operations.hs12
1 files changed, 6 insertions, 6 deletions
diff --git a/Operations.hs b/Operations.hs
index 8a31d1e..574003f 100644
--- a/Operations.hs
+++ b/Operations.hs
@@ -252,13 +252,13 @@ setButtonGrab grab w = withDisplay $ \d -> io $ do
-- | Set the focus to the window on top of the stack, or root
setTopFocus :: X ()
-setTopFocus = withWorkspace $ maybe (setFocusX =<< asks theRoot) setFocusX . W.peek
+setTopFocus = withWindowSet $ maybe (setFocusX =<< asks theRoot) setFocusX . W.peek
-- | Set focus explicitly to window 'w' if it is managed by us, or root.
-- This happens if X notices we've moved the mouse (and perhaps moved
-- the mouse to a new screen).
focus :: Window -> X ()
-focus w = withWorkspace $ \s -> do
+focus w = withWindowSet $ \s -> do
if W.member w s then modify (\st -> st { windowset = W.focusWindow w s }) >> setFocusX w -- >> refresh
else whenX (isRoot w) $ setFocusX w -- we could refresh here, moving gap too.
-- XXX a focus change could be caused by switching workspaces in xinerama.
@@ -269,7 +269,7 @@ focus w = withWorkspace $ \s -> do
-- | Call X to set the keyboard focus details.
setFocusX :: Window -> X ()
-setFocusX w = withWorkspace $ \ws -> do
+setFocusX w = withWindowSet $ \ws -> do
XConf { display = dpy , normalBorder = nbc, focusedBorder = fbc } <- ask
-- clear mouse button grab and border on other windows
@@ -391,15 +391,15 @@ layout f = do
-- | Return workspace visible on screen 'sc', or 0.
screenWorkspace :: ScreenId -> X WorkspaceId
-screenWorkspace sc = withWorkspace $ return . fromMaybe 0 . W.lookupWorkspace sc
+screenWorkspace sc = withWindowSet $ return . fromMaybe 0 . W.lookupWorkspace sc
-- | Apply an X operation to the currently focused window, if there is one.
withFocused :: (Window -> X ()) -> X ()
-withFocused f = withWorkspace $ \w -> whenJust (W.peek w) f
+withFocused f = withWindowSet $ \w -> whenJust (W.peek w) f
-- | True if window is under management by us
isClient :: Window -> X Bool
-isClient w = withWorkspace $ return . W.member w
+isClient w = withWindowSet $ return . W.member w
------------------------------------------------------------------------
-- | Floating layer support