Fix a few warnings reported by GHC 9.0

This commit is contained in:
Tomas Janousek 2021-05-23 22:58:30 +01:00
parent 147e83cbd0
commit 43e35952c8
3 changed files with 2 additions and 4 deletions

View File

@ -38,7 +38,7 @@ module XMonad.Actions.Plane
)
where
import Data.Map hiding (split)
import Data.Map (Map, fromList)
import XMonad.Prelude
import XMonad

View File

@ -245,7 +245,6 @@ instance (DecorationStyle ds Window, Shrinker s) => LayoutModifier (Decoration d
let ndwrs = zip toAdd $ repeat (Nothing,Nothing)
ndecos <- resync (ndwrs ++ del_dwrs d dwrs) wrs
processState (s {decos = ndecos })
| otherwise = return (wrs, Nothing)
where
ws = map fst wrs

View File

@ -64,13 +64,12 @@ data ResizeScreen a = ResizeScreen ResizeMode Int
data ResizeMode = T | B | L | R deriving (Read, Show)
instance LayoutModifier ResizeScreen a where
modifyLayout m ws rect@(Rectangle x y w h)
modifyLayout m ws (Rectangle x y w h)
| ResizeScreen L i <- m = resize $ Rectangle (x + fi i) y (w - fi i) h
| ResizeScreen R i <- m = resize $ Rectangle x y (w - fi i) h
| ResizeScreen T i <- m = resize $ Rectangle x (y + fi i) w (h - fi i)
| ResizeScreen B i <- m = resize $ Rectangle x y w (h - fi i)
| WithNewScreen r <- m = resize r
| otherwise = resize rect
where resize nr = runLayout ws nr
pureMess (ResizeScreen d _) m