From 52da5e54bd7d5283dc5c7b802c2f7e202322ccc7 Mon Sep 17 00:00:00 2001 From: nek0 Date: Wed, 21 Dec 2016 00:16:21 +0100 Subject: [PATCH] some refinement --- src/Affection.hs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Affection.hs b/src/Affection.hs index f0c0d93..460cc63 100644 --- a/src/Affection.hs +++ b/src/Affection.hs @@ -58,13 +58,13 @@ withAffection AffectionConfig{..} = do let (w, h) = (fromIntegral rw, fromIntegral rh) stride = fromIntegral (Raw.pixelFormatBytesPerPixel pixelFormat) * w cpp = B.babl_components_per_pixel bablFormat - initContainer <- return . (\x -> AffectionData + initContainer <- (\x -> AffectionData { quitEvent = False , userState = x , drawWindow = window , drawSurface = surface , drawStack = [] - }) =<< loadState surface + }) <$> loadState surface (_, nState) <- runStateT ( A.runState $ do preLoop liftIO $ SDL.surfaceBlit surface Nothing oldSurf Nothing