summaryrefslogtreecommitdiffstats
path: root/lib/Phi/Widgets/AlphaBox.hs
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Phi/Widgets/AlphaBox.hs')
-rw-r--r--lib/Phi/Widgets/AlphaBox.hs8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/Phi/Widgets/AlphaBox.hs b/lib/Phi/Widgets/AlphaBox.hs
index 6f989ea..59f8aea 100644
--- a/lib/Phi/Widgets/AlphaBox.hs
+++ b/lib/Phi/Widgets/AlphaBox.hs
@@ -13,11 +13,11 @@ import Control.Monad.State.Strict
import Graphics.Rendering.Cairo
-data AlphaBox w s c = (Widget w s c) => AlphaBox !Double !w
+data AlphaBox w s c d = (Widget w s c d) => AlphaBox !Double !w
-data AlphaBoxCache w s c = (Widget w s c) => AlphaBoxCache !c
+data AlphaBoxCache w s c d = (Widget w s c d) => AlphaBoxCache !c
-instance Eq s => Widget (AlphaBox w s c) s (AlphaBoxCache w s c) where
+instance (Eq s, Display d) => Widget (AlphaBox w s c d) s (AlphaBoxCache w s c d) d where
initWidget (AlphaBox _ w) = initWidget w
initCache (AlphaBox _ w) = AlphaBoxCache $ initCache w
@@ -47,6 +47,6 @@ instance Eq s => Widget (AlphaBox w s c) s (AlphaBoxCache w s c) where
handleMessage (AlphaBox _ w) = handleMessage w
-alphaBox :: (Widget w s c) => Double -> w -> AlphaBox w s c
+alphaBox :: (Widget w s c d) => Double -> w -> AlphaBox w s c d
alphaBox = AlphaBox