updated syntax in the mouse example
This commit is contained in:
parent
33831dba83
commit
e0d565005a
1 changed files with 4 additions and 4 deletions
|
@ -1,15 +1,15 @@
|
|||
|
||||
-- Move your mouse around above the canvas!
|
||||
|
||||
import Signal.Mouse (position)
|
||||
import Signal.Window (dimensions)
|
||||
import Mouse (position)
|
||||
import Window (dimensions)
|
||||
|
||||
myBlue = rgb 0 85 170
|
||||
myGreen = rgba 28 267 85 (1/2)
|
||||
|
||||
scene (x,y) (w,h) =
|
||||
collage w h [ filled myBlue . rotate ((x+y)/1000) $ ngon 4 100 (200,200)
|
||||
collage w h [ rotate (toFloat (x+y) / 1000) $ filled myBlue $ ngon 4 100 (200,200)
|
||||
, filled myGreen $ ngon 5 30 (x,y)
|
||||
]
|
||||
|
||||
main = lift2 scene position dimensions
|
||||
main = lift2 scene Mouse.position Window.dimensions
|
||||
|
|
Loading…
Reference in a new issue