From 919774dff82342cd7203d0fec92b6d045f334c4c Mon Sep 17 00:00:00 2001 From: Spencer Janssen Date: Wed, 15 Aug 2007 03:15:21 +0000 Subject: [PATCH] Operations.windows: minor refactor --- Operations.hs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/Operations.hs b/Operations.hs index 3e2a561..ca91dcb 100644 --- a/Operations.hs +++ b/Operations.hs @@ -141,9 +141,8 @@ windows f = do d <- asks display -- for each workspace, layout the currently visible workspaces - let allscreens = W.current ws : W.visible ws - each_visible = map (W.integrate' . W.stack . W.workspace) allscreens - summed_visible = reverse $ foldl (\ (x:xs) y -> ((x++y):x:xs)) [[]] each_visible + let allscreens = W.current ws : W.visible ws + summed_visible = scanl (++) [] $ map (W.integrate' . W.stack . W.workspace) allscreens visible <- fmap concat $ forM (zip allscreens summed_visible) $ \ (w, vis) -> do let n = W.tag (W.workspace w) this = W.view n ws