]> git.0d.be Git - empathy.git/commitdiff
[contact-chooser] emit 'activate' on 'row-activated' as well
authorDanielle Madeley <danielle.madeley@collabora.co.uk>
Thu, 20 Oct 2011 04:29:51 +0000 (15:29 +1100)
committerDanielle Madeley <danielle.madeley@collabora.co.uk>
Thu, 20 Oct 2011 04:29:51 +0000 (15:29 +1100)
This means the selection can be activated when the treeview is focused.

libempathy-gtk/empathy-contact-chooser.c

index 1e61667fae9f1e4ccba933aec9189522c3da6381..5444ff5ad79ab818aedc2f0303d7685ce9c59bb7 100644 (file)
@@ -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);