diff options
Diffstat (limited to 'gix.hs')
-rw-r--r-- | gix.hs | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -1,5 +1,7 @@ | |||
1 | {-# LANGUAGE OverloadedLabels #-} | 1 | {-# LANGUAGE OverloadedLabels #-} |
2 | {-# LANGUAGE OverloadedStrings #-} | 2 | {-# LANGUAGE OverloadedStrings #-} |
3 | {-# LANGUAGE TypeApplications #-} | ||
4 | {-# LANGUAGE CPP #-} | ||
3 | module Main where | 5 | module Main where |
4 | 6 | ||
5 | import GI.Gtk as Gtk hiding (main) | 7 | import GI.Gtk as Gtk hiding (main) |
@@ -25,7 +27,11 @@ main = do | |||
25 | _ <- on gl #realize $ R.realize st gl | 27 | _ <- on gl #realize $ R.realize st gl |
26 | _ <- on gl #unrealize $ R.unrealize st gl | 28 | _ <- on gl #unrealize $ R.unrealize st gl |
27 | _ <- on gl #render $ R.render st gl | 29 | _ <- on gl #render $ R.render st gl |
30 | #if MIN_VERSION_haskell_gi_base(0,22,0) | ||
31 | typ <- gobjectType @GLArea | ||
32 | #else | ||
28 | typ <- gobjectType gl | 33 | typ <- gobjectType gl |
34 | #endif | ||
29 | ccSig <- signalLookup "create-context" typ | 35 | ccSig <- signalLookup "create-context" typ |
30 | ccid <- signalHandlerFind gl [SignalMatchTypeId] ccSig | 36 | ccid <- signalHandlerFind gl [SignalMatchTypeId] ccSig |
31 | 0 -- detail | 37 | 0 -- detail |