module WildBind.FrontEnd
( FrontEvent (..)
, FrontEnd (..)
) where
import WildBind.Description (ActionDescription)
data FrontEvent s i
= FEInput i
| FEChange s
deriving (FrontEvent s i -> FrontEvent s i -> Bool
(FrontEvent s i -> FrontEvent s i -> Bool)
-> (FrontEvent s i -> FrontEvent s i -> Bool)
-> Eq (FrontEvent s i)
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
forall s i.
(Eq i, Eq s) =>
FrontEvent s i -> FrontEvent s i -> Bool
$c== :: forall s i.
(Eq i, Eq s) =>
FrontEvent s i -> FrontEvent s i -> Bool
== :: FrontEvent s i -> FrontEvent s i -> Bool
$c/= :: forall s i.
(Eq i, Eq s) =>
FrontEvent s i -> FrontEvent s i -> Bool
/= :: FrontEvent s i -> FrontEvent s i -> Bool
Eq, Eq (FrontEvent s i)
Eq (FrontEvent s i) =>
(FrontEvent s i -> FrontEvent s i -> Ordering)
-> (FrontEvent s i -> FrontEvent s i -> Bool)
-> (FrontEvent s i -> FrontEvent s i -> Bool)
-> (FrontEvent s i -> FrontEvent s i -> Bool)
-> (FrontEvent s i -> FrontEvent s i -> Bool)
-> (FrontEvent s i -> FrontEvent s i -> FrontEvent s i)
-> (FrontEvent s i -> FrontEvent s i -> FrontEvent s i)
-> Ord (FrontEvent s i)
FrontEvent s i -> FrontEvent s i -> Bool
FrontEvent s i -> FrontEvent s i -> Ordering
FrontEvent s i -> FrontEvent s i -> FrontEvent s i
forall a.
Eq a =>
(a -> a -> Ordering)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> a)
-> (a -> a -> a)
-> Ord a
forall s i. (Ord i, Ord s) => Eq (FrontEvent s i)
forall s i.
(Ord i, Ord s) =>
FrontEvent s i -> FrontEvent s i -> Bool
forall s i.
(Ord i, Ord s) =>
FrontEvent s i -> FrontEvent s i -> Ordering
forall s i.
(Ord i, Ord s) =>
FrontEvent s i -> FrontEvent s i -> FrontEvent s i
$ccompare :: forall s i.
(Ord i, Ord s) =>
FrontEvent s i -> FrontEvent s i -> Ordering
compare :: FrontEvent s i -> FrontEvent s i -> Ordering
$c< :: forall s i.
(Ord i, Ord s) =>
FrontEvent s i -> FrontEvent s i -> Bool
< :: FrontEvent s i -> FrontEvent s i -> Bool
$c<= :: forall s i.
(Ord i, Ord s) =>
FrontEvent s i -> FrontEvent s i -> Bool
<= :: FrontEvent s i -> FrontEvent s i -> Bool
$c> :: forall s i.
(Ord i, Ord s) =>
FrontEvent s i -> FrontEvent s i -> Bool
> :: FrontEvent s i -> FrontEvent s i -> Bool
$c>= :: forall s i.
(Ord i, Ord s) =>
FrontEvent s i -> FrontEvent s i -> Bool
>= :: FrontEvent s i -> FrontEvent s i -> Bool
$cmax :: forall s i.
(Ord i, Ord s) =>
FrontEvent s i -> FrontEvent s i -> FrontEvent s i
max :: FrontEvent s i -> FrontEvent s i -> FrontEvent s i
$cmin :: forall s i.
(Ord i, Ord s) =>
FrontEvent s i -> FrontEvent s i -> FrontEvent s i
min :: FrontEvent s i -> FrontEvent s i -> FrontEvent s i
Ord, Int -> FrontEvent s i -> ShowS
[FrontEvent s i] -> ShowS
FrontEvent s i -> String
(Int -> FrontEvent s i -> ShowS)
-> (FrontEvent s i -> String)
-> ([FrontEvent s i] -> ShowS)
-> Show (FrontEvent s i)
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
forall s i. (Show i, Show s) => Int -> FrontEvent s i -> ShowS
forall s i. (Show i, Show s) => [FrontEvent s i] -> ShowS
forall s i. (Show i, Show s) => FrontEvent s i -> String
$cshowsPrec :: forall s i. (Show i, Show s) => Int -> FrontEvent s i -> ShowS
showsPrec :: Int -> FrontEvent s i -> ShowS
$cshow :: forall s i. (Show i, Show s) => FrontEvent s i -> String
show :: FrontEvent s i -> String
$cshowList :: forall s i. (Show i, Show s) => [FrontEvent s i] -> ShowS
showList :: [FrontEvent s i] -> ShowS
Show)
data FrontEnd s i
= FrontEnd
{ forall s i. FrontEnd s i -> i -> ActionDescription
frontDefaultDescription :: i -> ActionDescription
, forall s i. FrontEnd s i -> i -> IO ()
frontSetGrab :: i -> IO ()
, forall s i. FrontEnd s i -> i -> IO ()
frontUnsetGrab :: i -> IO ()
, forall s i. FrontEnd s i -> IO (FrontEvent s i)
frontNextEvent :: IO (FrontEvent s i)
}