aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2014-05-31 21:00:13 +0000
committerChristian Grothoff <christian@grothoff.org>2014-05-31 21:00:13 +0000
commit338e527f87b490f94a30fcdf5fb5f714da6c48a5 (patch)
treee3d8d2816ef5a9ff48213c29d134edece7a86789
parent927d9db8c962c548c0771e401e3b627c4f23da64 (diff)
downloadgnunet-gtk-338e527f87b490f94a30fcdf5fb5f714da6c48a5.tar.gz
gnunet-gtk-338e527f87b490f94a30fcdf5fb5f714da6c48a5.zip
hide unsynchronized contacts tree view
-rw-r--r--src/conversation/gnunet-conversation-gtk_contacts.c18
1 files changed, 12 insertions, 6 deletions
diff --git a/src/conversation/gnunet-conversation-gtk_contacts.c b/src/conversation/gnunet-conversation-gtk_contacts.c
index 0b3023d3..e8bb80d6 100644
--- a/src/conversation/gnunet-conversation-gtk_contacts.c
+++ b/src/conversation/gnunet-conversation-gtk_contacts.c
@@ -64,6 +64,11 @@ static GtkTreeModel *contacts_treemodel;
64 */ 64 */
65static struct GNUNET_NAMESTORE_ZoneMonitor *zone_mon; 65static struct GNUNET_NAMESTORE_ZoneMonitor *zone_mon;
66 66
67/**
68 * The tree view widget.
69 */
70static GtkWidget *contacts_treeview;
71
67 72
68/** 73/**
69 * A row was activated in the contacts list. Initiate call. 74 * A row was activated in the contacts list. Initiate call.
@@ -139,6 +144,7 @@ display_record (void *cls,
139 { 144 {
140 /* disconnect, clear (and possibly freeze) view */ 145 /* disconnect, clear (and possibly freeze) view */
141 gtk_list_store_clear (contacts_liststore); 146 gtk_list_store_clear (contacts_liststore);
147 gtk_widget_hide (contacts_treeview);
142 return; 148 return;
143 } 149 }
144 do_display = FALSE; 150 do_display = FALSE;
@@ -224,7 +230,7 @@ display_record (void *cls,
224static void 230static void
225unfreeze_view (void *cls) 231unfreeze_view (void *cls)
226{ 232{
227 // tbd 233 gtk_widget_show (contacts_treeview);
228} 234}
229 235
230 236
@@ -250,6 +256,7 @@ gnunet_conversation_gtk_contacts_zone_combobox_changed_cb (GtkComboBox *widget,
250 zone_mon = NULL; 256 zone_mon = NULL;
251 } 257 }
252 gtk_list_store_clear (contacts_liststore); 258 gtk_list_store_clear (contacts_liststore);
259 gtk_widget_hide (contacts_treeview);
253 zone_mon = GNUNET_NAMESTORE_zone_monitor_start (GCG_get_configuration (), 260 zone_mon = GNUNET_NAMESTORE_zone_monitor_start (GCG_get_configuration (),
254 temp_zone_pkey, 261 temp_zone_pkey,
255 GNUNET_YES, 262 GNUNET_YES,
@@ -265,12 +272,11 @@ gnunet_conversation_gtk_contacts_zone_combobox_changed_cb (GtkComboBox *widget,
265void 272void
266GCG_CONTACTS_init () 273GCG_CONTACTS_init ()
267{ 274{
268#if GTK_CHECK_VERSION(3,10,0)
269 GtkTreeView *contacts_treeview;
270
271 contacts_treeview 275 contacts_treeview
272 = GTK_TREE_VIEW (GCG_get_main_window_object ("gnunet_conversation_gtk_treeview")); 276 = GTK_WIDGET (GCG_get_main_window_object
273 gtk_tree_view_set_activate_on_single_click (contacts_treeview, 277 ("gnunet_conversation_gtk_treeview"));
278#if GTK_CHECK_VERSION(3,10,0)
279 gtk_tree_view_set_activate_on_single_click (GTK_TREE_VIEW (contacts_treeview),
274 TRUE); 280 TRUE);
275#endif 281#endif
276 contacts_liststore 282 contacts_liststore