Use strict tuples for SPics
This commit is contained in:
@@ -17,20 +17,18 @@ drawSwitch col1 col2 bt
|
||||
| _btState bt == BtOff = flick $ pi / 4
|
||||
| otherwise = flick (negate (pi / 4))
|
||||
where
|
||||
flick a =
|
||||
flick a = noPic
|
||||
( mconcat
|
||||
[ colorSH col1 . upperBox Small Typical 20 $ reverse $ rectNSWE (-2) (-5) (-10) 10
|
||||
, colorSH col2 . translateSH (V3 0 (-2) 20) . rotateSH a . upperBox Small Typical 2 $
|
||||
reverse $
|
||||
rectNSWE 10 0 (-2) 2
|
||||
]
|
||||
, mempty
|
||||
)
|
||||
|
||||
defaultDrawButton :: Color -> Button -> SPic
|
||||
defaultDrawButton col bt =
|
||||
defaultDrawButton col bt = noPic
|
||||
( translateSHz 15 . colorSH col $ upperBox Small Typical 5 buttonGeometry
|
||||
, mempty
|
||||
)
|
||||
where
|
||||
buttonGeometry
|
||||
|
||||
Reference in New Issue
Block a user