diff options
-rw-r--r-- | Operations.hs | 2 |
1 files changed, 1 insertions, 1 deletions
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. |