From 5dfe50002b64c19dab9625360165a3415f03eb99 Mon Sep 17 00:00:00 2001 From: Andre Noll Date: Wed, 6 Jul 2022 00:13:21 +0200 Subject: [PATCH] gui: Don't show items in menus. The numbers at the right of each item are of little value. This patch gets rid of them, which also simplifies the code a bit. --- gui | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/gui b/gui index e9eb1a8..72ddb28 100644 --- a/gui +++ b/gui @@ -97,15 +97,13 @@ _gsu_menu() { local header="${1:-root}" local items="$2" - local i opts num=0 + local geom _get_geometry - opts="$result 16" - for i in $items; do - let num++ - opts+=" $i $num" - done - result="$(dialog --menu "$gsu_banner_txt ($header)" $opts 3>&1 1>&2 2>&3 3>&-)" + geom=$result + result="$(dialog --no-lines --no-items --menu \ + "$gsu_banner_txt ($header)" \ + $geom 16 $items 3>&1 1>&2 2>&3 3>&-)" _set_dialog_ret $? } -- 2.39.5