aboutsummaryrefslogtreecommitdiffstats
path: root/libempathy-gtk/empathy-account-widget-salut.c
diff options
context:
space:
mode:
authorXavier Claessens <xclaesse@src.gnome.org>2008-01-19 08:24:39 +0800
committerXavier Claessens <xclaesse@src.gnome.org>2008-01-19 08:24:39 +0800
commitd0e8b67fe27465caf63f783e727ae176e8a4166a (patch)
treec0807f72b8a3fbbb351e741d20a053c16a7874fe /libempathy-gtk/empathy-account-widget-salut.c
parentb06aa6d69e7bdfec0b755812f1b7e1386e7cfc57 (diff)
downloadgsoc2013-empathy-d0e8b67fe27465caf63f783e727ae176e8a4166a.tar
gsoc2013-empathy-d0e8b67fe27465caf63f783e727ae176e8a4166a.tar.gz
gsoc2013-empathy-d0e8b67fe27465caf63f783e727ae176e8a4166a.tar.bz2
gsoc2013-empathy-d0e8b67fe27465caf63f783e727ae176e8a4166a.tar.lz
gsoc2013-empathy-d0e8b67fe27465caf63f783e727ae176e8a4166a.tar.xz
gsoc2013-empathy-d0e8b67fe27465caf63f783e727ae176e8a4166a.tar.zst
gsoc2013-empathy-d0e8b67fe27465caf63f783e727ae176e8a4166a.zip
Unset account parameter if user gives an empthy value.
svn path=/trunk/; revision=579
Diffstat (limited to 'libempathy-gtk/empathy-account-widget-salut.c')
-rw-r--r--libempathy-gtk/empathy-account-widget-salut.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/libempathy-gtk/empathy-account-widget-salut.c b/libempathy-gtk/empathy-account-widget-salut.c
index 5d9bba9ff..78dce2312 100644
--- a/libempathy-gtk/empathy-account-widget-salut.c
+++ b/libempathy-gtk/empathy-account-widget-salut.c
@@ -31,10 +31,13 @@
#include <libmissioncontrol/mc-profile.h>
#include <libempathy/empathy-utils.h>
+#include <libempathy/empathy-debug.h>
#include "empathy-account-widget-salut.h"
#include "empathy-ui-utils.h"
+#define DEBUG_DOMAIN "AccountWidgetMSN"
+
typedef struct {
McAccount *account;
@@ -78,14 +81,16 @@ account_widget_salut_entry_focus_cb (GtkWidget *widget,
}
str = gtk_entry_get_text (GTK_ENTRY (widget));
-
if (G_STR_EMPTY (str)) {
gchar *value = NULL;
+ mc_account_unset_param (settings->account, param);
mc_account_get_param_string (settings->account, param, &value);
+ empathy_debug (DEBUG_DOMAIN, "Unset %s and restore to %s", param, value);
gtk_entry_set_text (GTK_ENTRY (widget), value ? value : "");
g_free (value);
} else {
+ empathy_debug (DEBUG_DOMAIN, "Setting %s to %s", param, str);
mc_account_set_param_string (settings->account, param, str);
}