summaryrefslogtreecommitdiffstats
path: root/src/ui
diff options
context:
space:
mode:
authorP. J. McDermott <pj@pehjota.net>2015-10-29 22:07:36 (EDT)
committer P. J. McDermott <pj@pehjota.net>2015-10-29 22:07:36 (EDT)
commitffc1bdaf355d6e7c7496ac79149575291e66377d (patch)
tree6983b381755345b0abd59e1defd09e44b2246ac4 /src/ui
parentd1bedaca10ed4c5983eb2c3381896525a4d4d403 (diff)
downloadfirman.sh-ffc1bdaf355d6e7c7496ac79149575291e66377d.zip
firman.sh-ffc1bdaf355d6e7c7496ac79149575291e66377d.tar.gz
firman.sh-ffc1bdaf355d6e7c7496ac79149575291e66377d.tar.bz2
show_menu(): Add initial value parameter
Diffstat (limited to 'src/ui')
-rw-r--r--src/ui/cli.sh5
-rw-r--r--src/ui/tui.sh6
2 files changed, 6 insertions, 5 deletions
diff --git a/src/ui/cli.sh b/src/ui/cli.sh
index 369694c..4b2854c 100644
--- a/src/ui/cli.sh
+++ b/src/ui/cli.sh
@@ -105,8 +105,9 @@ cli_show_menu()
cli_show_prompt()
{
local title="${1}"
- local len=${2}
- shift 2
+ local input="${2}"
+ local len=${3}
+ shift 3
local input=''
printf '%s\n' "${title}" >"${cli_tty}"
diff --git a/src/ui/tui.sh b/src/ui/tui.sh
index 75ef4e6..e0ae20b 100644
--- a/src/ui/tui.sh
+++ b/src/ui/tui.sh
@@ -327,15 +327,15 @@ tui_show_menu()
tui_show_prompt()
{
local title="${1}"
- local len=${2}
- shift 2
+ local input="${2}"
+ local len=${3}
+ shift 3
local w=
local y=
local x=
local i=
local iline=''
local bline=''
- local input=''
local curpos=0
local focus=0
local key=