From aa6e14bde4f482918f6f40108b67b4e83153cb36 Mon Sep 17 00:00:00 2001 From: Spencer Janssen Date: Mon, 4 Jun 2007 22:16:39 +0200 Subject: Use 'windows' in 'focus' darcs-hash:20070604201639-a5988-07a811aea77e4e22ae853cd09ddb3a6cd3e1cd61 --- Operations.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Operations.hs') diff --git a/Operations.hs b/Operations.hs index 3736081..6e87d05 100644 --- a/Operations.hs +++ b/Operations.hs @@ -258,7 +258,7 @@ setTopFocus = withWindowSet $ maybe (setFocusX =<< asks theRoot) setFocusX . W.p -- the mouse to a new screen). focus :: Window -> X () focus w = withWindowSet $ \s -> do - if W.member w s then modify (\st -> st { windowset = W.focusWindow w s }) >> refresh + if W.member w s then windows (W.focusWindow w) else whenX (isRoot w) $ setFocusX w -- | Call X to set the keyboard focus details. -- cgit v1.2.3