removed unnecessary KeyEvents definition

This commit is contained in:
Jonathan Lamothe 2024-08-22 16:20:34 -04:00
parent 014ca39103
commit 84415db96a

View File

@ -34,7 +34,6 @@ import Brick.Keybindings
, KeyConfig , KeyConfig
, KeyDispatcher , KeyDispatcher
, KeyEventHandler , KeyEventHandler
, KeyEvents
, bind , bind
, ctrl , ctrl
, keyDispatcher , keyDispatcher
@ -56,7 +55,7 @@ appKeyDispatcher = fromRight (error "can't build key dispatcher") $
-- | The key configuration -- | The key configuration
keyConfig :: KeyConfig KeyEventID keyConfig :: KeyConfig KeyEventID
keyConfig = newKeyConfig appKeyEvents keyBindings [] keyConfig = newKeyConfig (keyEvents []) keyBindings []
-- | Binds a "KeyEventID" to its associated action -- | Binds a "KeyEventID" to its associated action
eventBindings :: [KeyEventHandler KeyEventID (EventM () AppState)] eventBindings :: [KeyEventHandler KeyEventID (EventM () AppState)]
@ -68,10 +67,6 @@ eventBindings =
modify moveDown modify moveDown
] ]
-- | Names the individual key events
appKeyEvents :: KeyEvents KeyEventID
appKeyEvents = keyEvents [( "quit", QuitE )]
-- | Key bindings -- | Key bindings
keyBindings :: [(KeyEventID, [Binding])] keyBindings :: [(KeyEventID, [Binding])]
keyBindings = keyBindings =