aboutsummaryrefslogtreecommitdiffstats
path: root/Combo.hs
diff options
context:
space:
mode:
authorDavid Roundy <droundy@darcs.net>2007-09-29 21:12:38 +0200
committerDavid Roundy <droundy@darcs.net>2007-09-29 21:12:38 +0200
commit2e07689ceadaea1853c1228d14346853223be942 (patch)
tree69a6f1aed8bf082fd711a366baf3bf62534d9145 /Combo.hs
parent7c1d1059d2626927bbc553f0efccb0b472fa569f (diff)
downloadXMonadContrib-2e07689ceadaea1853c1228d14346853223be942.tar.gz
XMonadContrib-2e07689ceadaea1853c1228d14346853223be942.tar.xz
XMonadContrib-2e07689ceadaea1853c1228d14346853223be942.zip
some renaming of classes and data types.
darcs-hash:20070929191238-72aca-ceb0f2a89b35460e87cf9ff935f786b5a6028fb5.gz
Diffstat (limited to 'Combo.hs')
-rw-r--r--Combo.hs12
1 files changed, 6 insertions, 6 deletions
diff --git a/Combo.hs b/Combo.hs
index 72463d5..f4ab4b0 100644
--- a/Combo.hs
+++ b/Combo.hs
@@ -50,15 +50,15 @@ import qualified StackSet as W ( differentiate )
-- %import XMonadContrib.Combo
-- %layout , combo (twoPane 0.03 0.5) [(full,1),(tabbed shrinkText defaultTConf,1)]
-combo :: (Eq a, Show a, Read a, ReadableSomeLayout a, Layout l (SomeLayout a, Int))
- => (l (SomeLayout a, Int)) -> [(SomeLayout a, Int)] -> Combo l a
+combo :: (Eq a, Show a, Read a, ReadableLayout a, LayoutClass l (Layout a, Int))
+ => (l (Layout a, Int)) -> [(Layout a, Int)] -> Combo l a
combo = Combo []
-data Combo l a = Combo [a] (l (SomeLayout a, Int)) [(SomeLayout a, Int)]
+data Combo l a = Combo [a] (l (Layout a, Int)) [(Layout a, Int)]
deriving ( Show, Read )
-instance (Eq a, Show a, Read a, ReadableSomeLayout a, Layout l (SomeLayout a, Int))
- => Layout (Combo l) a where
+instance (Eq a, Show a, Read a, ReadableLayout a, LayoutClass l (Layout a, Int))
+ => LayoutClass (Combo l) a where
doLayout (Combo f super origls) rinput s = arrange (integrate s)
where arrange [] = return ([], Just $ Combo [] super origls)
arrange [w] = return ([(w,rinput)], Just $ Combo [w] super origls)
@@ -89,7 +89,7 @@ instance (Eq a, Show a, Read a, ReadableSomeLayout a, Layout l (SomeLayout a, In
Just [super'] -> return $ Just $ Combo f super' $ maybe origls id mls'
_ -> return $ Combo f super `fmap` mls'
-broadcastPrivate :: Layout l b => SomeMessage -> [l b] -> X (Maybe [l b])
+broadcastPrivate :: LayoutClass l b => SomeMessage -> [l b] -> X (Maybe [l b])
broadcastPrivate a ol = do nml <- mapM f ol
if any isJust nml
then return $ Just $ zipWith ((flip maybe) id) ol nml