Enter was swallowed as well
@@ -10,7 +10,12 @@ import (
func CreateFocusTextViewOnTypeInputHandler(treeView *tview.Box, app *tview.Application, component *tview.TextView) func(event *tcell.EventKey) *tcell.EventKey {
eventHandler := func(event *tcell.EventKey) *tcell.EventKey {
- if event.Rune() != 0 && event.Modifiers() == tcell.ModNone {
+ if event.Modifiers() == tcell.ModNone {
+ if event.Key() == tcell.KeyEnter {
+ return event
+ }
+
+ if event.Rune() != 0 {
inputHandler := component.InputHandler()
if inputHandler != nil {
app.SetFocus(component)
@@ -18,6 +23,7 @@ func CreateFocusTextViewOnTypeInputHandler(treeView *tview.Box, app *tview.Appli
return nil
}
}
+ }
return event
}
