From df96c6a78618f47c7b14cb8338cd500dbcce6dfe Mon Sep 17 00:00:00 2001 From: P. J. McDermott Date: Thu, 29 Oct 2015 15:22:42 -0400 Subject: tui_show_prompt(): Limit inserts by input length, not cursor position --- diff --git a/src/ui/tui.sh b/src/ui/tui.sh index 76da51c..2a9a1cd 100644 --- a/src/ui/tui.sh +++ b/src/ui/tui.sh @@ -434,7 +434,7 @@ tui_show_prompt() "${cmd}")" ;; KEY_SPACE) - [ ${curpos} -lt ${len} ] || continue + [ ${#input} -lt ${len} ] || continue key=' ' i=0 mask='' @@ -458,7 +458,7 @@ tui_show_prompt() ;; KEY_*);; *) - [ ${curpos} -lt ${len} ] || continue + [ ${#input} -lt ${len} ] || continue i=0 mask='' while [ ${i} -lt ${curpos} ]; do -- cgit v0.9.1