mirror of
https://github.com/xmonad/xmonad-contrib.git
synced 2025-07-30 11:41:51 -07:00
Apply hlint hints
All hints are applied in one single commit, as a commit per hint would result in 80+ separate commits—tihs is really just too much noise. Related: https://github.com/xmonad/xmonad-contrib/issues/537
This commit is contained in:
@@ -41,8 +41,8 @@ import XMonad.Prelude (fromMaybe)
|
||||
|
||||
ifWider :: (LayoutClass l1 a, LayoutClass l2 a)
|
||||
=> Dimension -- ^ target screen width
|
||||
-> (l1 a) -- ^ layout to use when the screen is wide enough
|
||||
-> (l2 a) -- ^ layout to use otherwise
|
||||
-> l1 a -- ^ layout to use when the screen is wide enough
|
||||
-> l2 a -- ^ layout to use otherwise
|
||||
-> PerScreen l1 l2 a
|
||||
ifWider w = PerScreen w False
|
||||
|
||||
@@ -57,7 +57,7 @@ mkNewPerScreenT (PerScreen w _ lt lf) mlt' =
|
||||
mkNewPerScreenF :: PerScreen l1 l2 a -> Maybe (l2 a) ->
|
||||
PerScreen l1 l2 a
|
||||
mkNewPerScreenF (PerScreen w _ lt lf) mlf' =
|
||||
(\lf' -> PerScreen w False lt lf') $ fromMaybe lf mlf'
|
||||
PerScreen w False lt $ fromMaybe lf mlf'
|
||||
|
||||
instance (LayoutClass l1 a, LayoutClass l2 a, Show a) => LayoutClass (PerScreen l1 l2) a where
|
||||
runLayout (W.Workspace i p@(PerScreen w _ lt lf) ms) r
|
||||
@@ -68,7 +68,7 @@ instance (LayoutClass l1 a, LayoutClass l2 a, Show a) => LayoutClass (PerScreen
|
||||
|
||||
handleMessage (PerScreen w bool lt lf) m
|
||||
| bool = handleMessage lt m >>= maybe (return Nothing) (\nt -> return . Just $ PerScreen w bool nt lf)
|
||||
| otherwise = handleMessage lf m >>= maybe (return Nothing) (\nf -> return . Just $ PerScreen w bool lt nf)
|
||||
| otherwise = handleMessage lf m >>= maybe (return Nothing) (return . Just . PerScreen w bool lt)
|
||||
|
||||
description (PerScreen _ True l1 _) = description l1
|
||||
description (PerScreen _ _ _ l2) = description l2
|
||||
|
Reference in New Issue
Block a user