@@ -34,6 +34,7 @@ module Reflex.Class
34 , mergeMap
34 , mergeMap
35 , mergeList
35 , mergeList
36 , mergeWith
36 , mergeWith
37 -- ** Breaking up 'Event's
38 -- ** Breaking up 'Event's
39 , fanEither
40 , fanEither
@@ -703,6 +704,18 @@ distributeListOverDyn = distributeListOverDynWith id
703distributeListOverDynWith :: Reflex t => ([a] -> b) -> [Dynamic t a] -> Dynamic t b
704distributeListOverDynWith :: Reflex t => ([a] -> b) -> [Dynamic t a] -> Dynamic t b
704distributeListOverDynWith f = fmap (f . map (\(Const2 _ :=> Identity v) -> v) . DMap.toList) . distributeDMapOverDynPure . DMap.fromList . map (\(k, v) -> Const2 k :=> v) . zip [0 :: Int ..]
705distributeListOverDynWith f = fmap (f . map (\(Const2 _ :=> Identity v) -> v) . DMap.toList) . distributeDMapOverDynPure . DMap.fromList . map (\(k, v) -> Const2 k :=> v) . zip [0 :: Int ..]
707+-- | Create a new 'Event' that occurs when the first supplied 'Event' occurs
708+-- unless the second supplied 'Event' occurs simultaneously.
709+unlessE :: Reflex t => Event t a -> Event t b -> Event t a
713+ $ DMap.fromList [LeftTag DMap.:=> ea, RightTag DMap.:=> eb]
715+ dmapper m = case (DMap.lookup LeftTag m, DMap.lookup RightTag m) of
716+ (Just (Identity a), Nothing) -> Just a
707--------------------------------------------------------------------------------
720--------------------------------------------------------------------------------
708-- Accumulator
721-- Accumulator