changeset 7921:c3dc33bb94dc

[gaim-migrate @ 8589] as twisted as this seems, it does seem to work committer: Tailor Script <tailor@pidgin.im>
author Nathan Walp <nwalp@pidgin.im>
date Tue, 23 Dec 2003 15:53:13 +0000
parents 74b03db5ba4f
children 1fb7a840b5c7
files src/gtkrequest.c
diffstat 1 files changed, 16 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/src/gtkrequest.c	Tue Dec 23 14:41:33 2003 +0000
+++ b/src/gtkrequest.c	Tue Dec 23 15:53:13 2003 +0000
@@ -812,6 +812,7 @@
 		else
 			rows = field_count;
 
+		col_num=0;
 		for (fl = field_list; fl != NULL; fl = fl->next)
 		{
 			GaimRequestFieldType type;
@@ -820,11 +821,19 @@
 
 			type = gaim_request_field_get_type(field);
 
-			if (type == GAIM_REQUEST_FIELD_STRING &&
-				gaim_request_field_string_is_multiline(field))
-			{
+			if (type == GAIM_REQUEST_FIELD_LABEL) {
+				if(col_num > 0)
+					rows++;
+				rows++;
+			} else if(type == GAIM_REQUEST_FIELD_STRING && gaim_request_field_string_is_multiline(field)){
+				if(col_num > 0)
+					rows++;
 				rows += 2;
 			}
+
+			col_num++;
+			if(col_num >= cols)
+				col_num=0;
 		}
 
 		table = gtk_table_new(rows, 2 * cols, FALSE);
@@ -872,11 +881,15 @@
 						(type == GAIM_REQUEST_FIELD_STRING &&
 						 gaim_request_field_string_is_multiline(field)))
 					{
+						if(col_num > 0)
+							row_num++;
+
 						gtk_table_attach_defaults(GTK_TABLE(table), label,
 												  0, 2 * cols,
 												  row_num, row_num + 1);
 
 						row_num++;
+						col_num=cols;
 					}
 					else
 					{