@@ -52,9 +52,14 @@ data Input = Input
5252 -- 'nextEvent' this will not refresh the display if the next event
5353 -- is an 'EvResize'.
5454 _eventChannel :: TChan Event
55− -- | Shuts down the input processing. This should return the
56− -- terminal input state to before he input initialized.
55+ -- | Shuts down the input processing. As part of shutting down the
56+ -- input, this should also restore the input state.
5757 , shutdownInput :: IO ()
58+ -- | Restore the terminal's input state to what it was prior
59+ -- to configuring input for Vty. This should be done as part of
60+ -- 'shutdownInput' but is exposed in case you need to access it
61+ -- directly.
62+ , restoreInputState :: IO ()
5863 -- | Changes to this value are reflected after the next event.
5964 , _configRef :: IORef Config
6065 -- | input debug log
@@ -235,6 +240,7 @@ initInput config classifyTable = do
235240 applyConfig fd config
236241 stopSync <- newEmptyMVar
237242 input <- Input <$> atomically newTChan
243+ <*> pure (return ())
238244 <*> pure (return ())
239245 <*> newIORef config
240246 <*> maybe (return Nothing)