changeset 27408:71e8748bc408

Close up scope on a variable and use PURPLE_BLIST_NODE_HAS_FLAG.
author Etan Reisner <pidgin@unreliablesource.net>
date Tue, 07 Jul 2009 15:50:45 +0000
parents b74fa3d29cda
children 531454a6026d beb9f969d06e
files pidgin/gtkblist.c
diffstat 1 files changed, 2 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/pidgin/gtkblist.c	Tue Jul 07 15:44:24 2009 +0000
+++ b/pidgin/gtkblist.c	Tue Jul 07 15:50:45 2009 +0000
@@ -1505,7 +1505,6 @@
 	PurpleContact *contact;
 	PurpleBlistNode *node;
 	gboolean contact_expanded = FALSE;
-	gboolean show_offline = FALSE;
 
 	g_return_if_fail(menu);
 	g_return_if_fail(buddy);
@@ -1573,8 +1572,8 @@
 				G_CALLBACK(gtk_blist_menu_showlog_cb), buddy, 0, 0, NULL);
 	}
 
-	if (!(purple_blist_node_get_flags(node) & PURPLE_BLIST_NODE_FLAG_NO_SAVE)) {
-		show_offline = purple_blist_node_get_bool(node, "show_offline");
+	if (!PURPLE_BLIST_NODE_HAS_FLAG(node, PURPLE_BLIST_NODE_FLAG_NO_SAVE)) {
+		gboolean show_offline = purple_blist_node_get_bool(node, "show_offline");
 		pidgin_new_item_from_stock(menu, show_offline ? _("Hide When Offline") : _("Show When Offline"),
 				NULL, G_CALLBACK(gtk_blist_menu_showoffline_cb), node, 0, 0, NULL);
 	}