don't refresh on focus events

leads to a race. this will affect how gaps are redrawn when moving to a
new screen with the mouse.
This commit is contained in:
Don Stewart
2007-05-28 13:31:27 +00:00
parent 5818e5a7fc
commit 0b8c9c407e

View File

@@ -220,7 +220,7 @@ setTopFocus = withWorkspace $ maybe (setFocusX =<< asks theRoot) setFocusX . W.p
-- the mouse to a new screen).
focus :: Window -> X ()
focus w = withWorkspace $ \s -> do
if W.member w s then modify (\st -> st { windowset = W.focusWindow w s }) >> refresh
if W.member w s then modify (\st -> st { windowset = W.focusWindow w s }) -- >> 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.
-- if so, and the gap is in use, the gap should probably follow the