packages feed

hsqml-demo-manic 0.3.4.0 → 0.3.5.0

raw patch · 3 files changed

+20/−16 lines, 3 filesdep ~MonadRandomdep ~containersdep ~hsqmlnew-uploader

Dependency ranges changed: MonadRandom, containers, hsqml, text

Files

hsqml-demo-manic.cabal view
@@ -1,12 +1,12 @@ Name:                hsqml-demo-manic-Version:             0.3.4.0+Version:             0.3.5.0 Cabal-version:       >=1.10 Build-type:          Simple License:             BSD3 License-file:        LICENSE-Copyright:           (c) 2014-2016 Robin KAY+Copyright:           (c) 2014-2016 Robin KAY, (c) 2025 Sascha-Oliver Prolic Author:              Robin KAY-Maintainer:          komadori@gekkou.co.uk+Maintainer:          saschaprolic@googlemail.com Homepage:            http://www.gekkou.co.uk/software/hsqml/ Category:            Game Synopsis:            HsQML-based clone of Pipe Mania@@ -14,7 +14,7 @@ Data-files:          *.qml *.svg Extra-source-files:  CHANGELOG Description:-    HsQML-based clone of Pipe Mania+    HsQML-based clone of Pipe Mania.  executable hsqml-manic     Default-language: Haskell2010@@ -26,12 +26,12 @@         TypeFamilies     Build-depends:         base        == 4.*,-        containers  >= 0.4   && < 0.6,-        text        >= 0.11  && < 1.3,-        MonadRandom >= 0.4   && < 0.5,-        hsqml       >= 0.3.4 && < 0.4+        containers  >= 0.4   && < 0.7,+        text        >= 2.0  && < 2.1,+        MonadRandom >= 0.4   && < 0.7,+        hsqml       >= 0.3.6 && < 0.4     GHC-options: -threaded  Source-repository head-    type:     darcs-    location: http://hub.darcs.net/komadori/hsqml-demo-manic+    type:     git+    location: https://github.com/prolic/hsqml-demo-manic
qml/Board.qml view
@@ -128,14 +128,14 @@          Connections {             target: mouseView.mouse;-            onPressed: {+            function onPressed() {                 if (mouseView.tilePlacable) {                     c.gridModel = c.gridModel.place(                         mouseView.tileX, mouseView.tileY, tileSource.top.tile);                     c.tileSource = c.tileSource.next;                 }                 c.pressedComplete();-            } +            }         }          visible: mouseView.mouse.containsMouse;@@ -194,11 +194,15 @@         }         Connections {             target: c;-            onPressedComplete: virtualMouse.pick();+            function onPressedComplete() {+                virtualMouse.pick();+            }         }         Connections {             target: c.gridModel;-            onPicked: virtualMouse.move(pos); +            function onPicked(pos) {+                virtualMouse.move(pos);+            }         }         property int mouseX : (tileX+0.5)*c.tileSize;         property int mouseY : (tileY+0.5)*c.tileSize;
src/Main.hs view
@@ -266,7 +266,7 @@  foldStarts :: (Colour -> Point -> a -> a) -> a -> Grid -> a foldStarts f s (Grid _ _ gridMap) =-    Map.foldWithKey (\curr tile a -> case tile of+    Map.foldrWithKey (\curr tile a -> case tile of         Start col _ -> f col curr a         _           -> a) s gridMap @@ -289,7 +289,7 @@  spareParts :: Grid -> [Plumb] spareParts (Grid _ _ grid) =-    Map.foldWithKey sparePart [] grid+    Map.foldrWithKey sparePart [] grid  sparePart :: Point -> Tile -> [Plumb] -> [Plumb] sparePart p (Start col theta) xs = Plumb col (-1) p Nothing (Just theta) : xs