aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavyd Madeley <davyd@madeley.id.au>2009-04-11 00:54:21 +0800
committerXavier Claessens <xclaesse@src.gnome.org>2009-04-11 00:54:21 +0800
commitecd39985a3892959e1bfe7aa24a9450163a47d32 (patch)
tree2eea1cdc70930bcc99db1c9fbad20717edce897c
parentbb48d20e2bf53f166a4342881eb061484451b14c (diff)
downloadgsoc2013-empathy-ecd39985a3892959e1bfe7aa24a9450163a47d32.tar
gsoc2013-empathy-ecd39985a3892959e1bfe7aa24a9450163a47d32.tar.gz
gsoc2013-empathy-ecd39985a3892959e1bfe7aa24a9450163a47d32.tar.bz2
gsoc2013-empathy-ecd39985a3892959e1bfe7aa24a9450163a47d32.tar.lz
gsoc2013-empathy-ecd39985a3892959e1bfe7aa24a9450163a47d32.tar.xz
gsoc2013-empathy-ecd39985a3892959e1bfe7aa24a9450163a47d32.tar.zst
gsoc2013-empathy-ecd39985a3892959e1bfe7aa24a9450163a47d32.zip
Commit the changed status message on focus-out.
I'm dubious if this is the right behaviour, but there was no obvious consensus. So I propose we find out with actual users. It can always be changed. From: Davyd Madeley <davyd@madeley.id.au> svn path=/trunk/; revision=2788
-rw-r--r--libempathy-gtk/empathy-presence-chooser.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/libempathy-gtk/empathy-presence-chooser.c b/libempathy-gtk/empathy-presence-chooser.c
index 0bb2ce0de..e8dbdfc61 100644
--- a/libempathy-gtk/empathy-presence-chooser.c
+++ b/libempathy-gtk/empathy-presence-chooser.c
@@ -465,6 +465,20 @@ combo_row_separator_func (GtkTreeModel *model,
return (type == ENTRY_TYPE_SEPARATOR);
}
+static gboolean
+focus_out_cb (EmpathyPresenceChooser *chooser, GdkEventFocus *event,
+ GtkEntry *entry)
+{
+ EmpathyPresenceChooserPriv *priv = GET_PRIV (chooser);
+
+ if (priv->editing_status)
+ {
+ entry_activate_cb (chooser, entry);
+ }
+
+ return FALSE;
+}
+
static void
empathy_presence_chooser_init (EmpathyPresenceChooser *chooser)
{
@@ -520,6 +534,8 @@ empathy_presence_chooser_init (EmpathyPresenceChooser *chooser)
G_CALLBACK (changed_cb), NULL);
g_signal_connect_swapped (entry, "changed",
G_CALLBACK (changed_cb), chooser);
+ g_signal_connect_swapped (entry, "focus-out-event",
+ G_CALLBACK (focus_out_cb), chooser);
priv->idle = empathy_idle_dup_singleton ();
presence_chooser_presence_changed_cb (chooser);