diff options
author | David Roundy <droundy@darcs.net> | 2007-06-12 17:05:55 +0200 |
---|---|---|
committer | David Roundy <droundy@darcs.net> | 2007-06-12 17:05:55 +0200 |
commit | f4f0f537620208cddb90eb3f72efd15f7d9b6768 (patch) | |
tree | 07c89936466799b92849fa9f64bbcd197cdb021b /Operations.hs | |
parent | 22ffd93fca26ba33369231a8554a6885714b0834 (diff) | |
download | xmonad-f4f0f537620208cddb90eb3f72efd15f7d9b6768.tar.gz xmonad-f4f0f537620208cddb90eb3f72efd15f7d9b6768.tar.xz xmonad-f4f0f537620208cddb90eb3f72efd15f7d9b6768.zip |
make focus, up and down complete functions.
This is a rerun of my change to make (Stack a) never be empty. Gives
us more type-safety.
darcs-hash:20070612150555-72aca-5f6e43aa33979c71679a73b44d93f9e2b8f9d2a8.gz
Diffstat (limited to 'Operations.hs')
-rw-r--r-- | Operations.hs | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/Operations.hs b/Operations.hs index 994b773..e03c0fd 100644 --- a/Operations.hs +++ b/Operations.hs @@ -134,7 +134,7 @@ windows f = do -- and must be called on all visible workspaces. broadcastMessage UnDoLayout XState { windowset = old, layouts = fls, xineScreens = xinesc, statusGaps = gaps } <- get - let oldvisible = concatMap (W.integrate . W.stack . W.workspace) $ W.current old : W.visible old + let oldvisible = concatMap (W.integrate' . W.stack . W.workspace) $ W.current old : W.visible old ws = f old modify (\s -> s { windowset = ws }) d <- asks display @@ -145,8 +145,7 @@ windows f = do this = W.view n ws Just l = fmap fst $ M.lookup n fls flt = filter (flip M.member (W.floating ws)) (W.index this) - tiled = W.filter (not . flip M.member (W.floating ws)) - . W.stack . W.workspace . W.current $ this + tiled = W.filter (not . flip M.member (W.floating ws)) . W.stack . W.workspace . W.current $ this (Rectangle sx sy sw sh) = genericIndex xinesc (W.screen w) (gt,gb,gl,gr) = genericIndex gaps (W.screen w) viewrect = Rectangle (sx + fromIntegral gl) (sy + fromIntegral gt) @@ -154,7 +153,7 @@ windows f = do -- just the tiled windows: -- now tile the windows on this workspace, modified by the gap - rs <- doLayout l viewrect tiled -- `mplus` doLayout full viewrect tiled + rs <- runLayout l viewrect tiled -- `mplus` doLayout full viewrect tiled mapM_ (uncurry tileWindow) rs -- now the floating windows: @@ -388,9 +387,7 @@ instance Message IncMasterN -- simple fullscreen mode, just render all windows fullscreen. -- a plea for tuple sections: map . (,sc) full :: Layout -full = Layout { doLayout = \sc ws -> return $ case ws of - W.Empty -> [] - (W.Node f _ _) -> [(f, sc)] +full = Layout { doLayout = \sc (W.Stack f _ _) -> return [(f, sc)] , modifyLayout = const (return Nothing) } -- no changes -- |