From c34e4255ffcb29d0aa39c262d68de3bc18095f57 Mon Sep 17 00:00:00 2001 From: Glynn Foster Date: Wed, 12 Nov 2003 01:14:17 +0000 Subject: =?UTF-8?q?Fix=20radiolist=20returning=20the=20wrong=20argument.?= =?UTF-8?q?=20Patch=20from=20Peter=20=C5strand?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 2003-11-12 Glynn Foster * src/gdialog.in: Fix radiolist returning the wrong argument. Patch from Peter Åstrand . Fixes #125672. --- src/gdialog.in | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'src') diff --git a/src/gdialog.in b/src/gdialog.in index b204532..72234d4 100755 --- a/src/gdialog.in +++ b/src/gdialog.in @@ -227,8 +227,8 @@ ARG: while ($argn < $args) { # an untitled column for the check or radio buttons # and the 'text' arg as a second column header - $command .= "--list $list --column='' --column \"$element\" "; - + $command .= "--list $list --column='' --column='' --column \"$element\" "; + # should output be line by line? if ($separator) { $command .= " --separator='\n' "; @@ -238,10 +238,10 @@ ARG: while ($argn < $args) { # bypassing height, width and list-height # from here args run [tag] [item] [status] ... - $argn += 5; + $argn += 4; # Loop over the remainder of the commandline - # discarding the 'status' and 'tag' args of each item + # discarding the 'status' args of each item # and using the 'item' for display in our second column # also pass a fake NULL argument since zenity can't set # the status of a row like gdialog can @@ -249,7 +249,10 @@ ARG: while ($argn < $args) { while ($argn < $args) { get_arg; $command .= "NULL \"$element\" "; - $argn += 3; + $argn += 1; + get_arg; + $command .= "\"$element\" "; + $argn += 2; } last ARG; } -- cgit v1.2.3-2-g168b