pidgin: c32c593e: Do not show hidden request fields.

sadrul at pidgin.im sadrul at pidgin.im
Wed Jul 15 02:35:48 EDT 2009


-----------------------------------------------------------------
Revision: c32c593ec4d83119cd8dd3c6faeb96bb4d0f30a1
Ancestor: b0c971fe484f0f8a191375c4f980736b6fbc5b33
Author: sadrul at pidgin.im
Date: 2009-07-15T06:35:19
Branch: im.pidgin.pidgin
URL: http://d.pidgin.im/viewmtn/revision/info/c32c593ec4d83119cd8dd3c6faeb96bb4d0f30a1

Modified files:
        finch/gntrequest.c

ChangeLog: 

Do not show hidden request fields.

-------------- next part --------------
============================================================
--- finch/gntrequest.c	bebb397405fd5e53b8cc8c2156683f9b62354f61
+++ finch/gntrequest.c	03677ade2ff146473e7c1ea079a52d3b0c025cdb
@@ -317,6 +317,8 @@ request_fields_cb(GntWidget *button, Pur
 		{
 			PurpleRequestField *field = fields->data;
 			PurpleRequestFieldType type = purple_request_field_get_type(field);
+			if (!purple_request_field_is_visible(field))
+				continue;
 			if (type == PURPLE_REQUEST_FIELD_BOOLEAN)
 			{
 				GntWidget *check = FINCH_GET_DATA(field);
@@ -598,11 +600,13 @@ finch_request_fields(const char *title, 
 
 		for (; fields ; fields = fields->next)
 		{
-			/* XXX: Break each of the fields into a separate function? */
 			PurpleRequestField *field = fields->data;
 			PurpleRequestFieldType type = purple_request_field_get_type(field);
 			const char *label = purple_request_field_get_label(field);
 
+			if (!purple_request_field_is_visible(field))
+				continue;
+
 			hbox = gnt_hbox_new(TRUE);   /* hrm */
 			gnt_box_add_widget(GNT_BOX(box), hbox);
 


More information about the Commits mailing list