diff options
-rw-r--r-- | src/Config.hs | 4 | ||||
-rw-r--r-- | src/Wetterhorn/Core.hs | 2 | ||||
-rw-r--r-- | src/Wetterhorn/FFI.hs | 5 |
3 files changed, 3 insertions, 8 deletions
diff --git a/src/Config.hs b/src/Config.hs index 14326cb..818150e 100644 --- a/src/Config.hs +++ b/src/Config.hs @@ -1,8 +1,6 @@ -module Config () where +module Config (wetterhorn) where import Wetterhorn.Core -foreign export ccall wetterhorn :: IO Wetterhorn - wetterhorn :: IO Wetterhorn wetterhorn = initWetterhorn defaultConfig diff --git a/src/Wetterhorn/Core.hs b/src/Wetterhorn/Core.hs index 7a5c0b1..33ce78d 100644 --- a/src/Wetterhorn/Core.hs +++ b/src/Wetterhorn/Core.hs @@ -50,7 +50,7 @@ defaultConfig = WConfig { keybindingHandler = \sym -> do i <- incrementState - wio (printf "[%d] Got key yolol %d\n" i sym), + wio (printf "[%d] Got key %d\n" i sym), surfaceHandler = \state ptr -> wio (printf "Surface %s is %s\n" (showHex (ptrToIntPtr ptr) "") (show state)) } diff --git a/src/Wetterhorn/FFI.hs b/src/Wetterhorn/FFI.hs index 1463396..1d74248 100644 --- a/src/Wetterhorn/FFI.hs +++ b/src/Wetterhorn/FFI.hs @@ -2,6 +2,7 @@ -- for the plugin. module Wetterhorn.FFI () where +import Config import Control.Monad (forM_) import qualified Data.ByteString as BS import qualified Data.ByteString.Char8 as CH @@ -42,10 +43,6 @@ runForeignWithReturn2 fn ptrA ptrB stableptr = do poke ptrB vB newStablePtr (conf, state') --- | This function should be defined somewhere in the code. This is kind of like --- the "main" function in XMonad. -foreign import ccall wetterhorn :: IO Wetterhorn - -- | This function is the implementation of the "hotstart" mechanism. It gives a -- pointer to the previously marshalled state and the length of that array and -- this function returns a Wetterhorn instance. |