diff options
| author | Hannes Schulze <haschu0103@outlook.de> | 2024-08-04 21:37:33 +0200 |
|---|---|---|
| committer | Hannes Schulze <haschu0103@outlook.de> | 2024-08-04 21:37:33 +0200 |
| commit | 3387f92245dae08bc1125829dd542ec2e13c28fd (patch) | |
| tree | 8e4048e6ff18605cf7c4e2968d4691d7db302db9 /highway | |
| parent | 049dfc4dc5341f6d0e0015dccbb54352351e9e14 (diff) | |
create globals
Diffstat (limited to 'highway')
| -rw-r--r-- | highway/Main.hs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/highway/Main.hs b/highway/Main.hs index 58049df..191279a 100644 --- a/highway/Main.hs +++ b/highway/Main.hs @@ -48,6 +48,7 @@ handleRequest r | Just (BindOutput o) <- fromRequest r = do outputs %= M.insert o Output sendEvent o $ WLOutput.EvGeometry geometry sendEvent o $ WLOutput.EvDone + liftIO $ putStrLn $ "Created output " ++ show o flushEvents | Just ReqSIGINT <- fromRequest r = do c <- interruptedCount <%= (+1) liftIO $ putStrLn $ "Received SIGINT " ++ show c ++ "/3" @@ -59,6 +60,6 @@ main = void $ withDisplay (State M.empty 0) $ do socket <- bindSocket liftIO $ putStrLn $ "Listening on socket: " ++ socket registerSignalEvent ReqSIGINT 2 - output <- registerGlobal BindOutput + output <- registerGlobal BindOutput 4 processRequests handleRequest unregisterGlobal output |
