From 1358b8ae4551e659e3a61a7d1dc41b768cab46ea Mon Sep 17 00:00:00 2001 From: Danielle Madeley Date: Thu, 20 Oct 2011 15:29:51 +1100 Subject: [contact-chooser] emit 'activate' on 'row-activated' as well This means the selection can be activated when the treeview is focused. --- libempathy-gtk/empathy-contact-chooser.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/libempathy-gtk/empathy-contact-chooser.c b/libempathy-gtk/empathy-contact-chooser.c index 1e61667fa..5444ff5ad 100644 --- a/libempathy-gtk/empathy-contact-chooser.c +++ b/libempathy-gtk/empathy-contact-chooser.c @@ -300,6 +300,15 @@ search_activate_cb (GtkEntry *entry, g_signal_emit (self, signals[SIG_ACTIVATE], 0); } +static void +view_activate_cb (GtkTreeView *view, + GtkTreePath *path, + GtkTreeViewColumn *column, + EmpathyContactChooser *self) +{ + g_signal_emit (self, signals[SIG_ACTIVATE], 0); +} + static void empathy_contact_chooser_init (EmpathyContactChooser *self) { @@ -346,6 +355,8 @@ empathy_contact_chooser_init (EmpathyContactChooser *self) g_signal_connect (selection, "changed", G_CALLBACK (view_selection_changed_cb), self); + g_signal_connect (self->priv->view, "row-activated", + G_CALLBACK (view_activate_cb), self); scroll = gtk_scrolled_window_new (NULL, NULL); -- cgit v1.2.3