From 4b6c138fa6cb7b29cc1e89a1eac64c69b78854ee Mon Sep 17 00:00:00 2001 From: Sivaiah Nallagatla Date: Wed, 16 Jun 2004 04:07:07 +0000 Subject: compare old and new full names and if it is different set the new the name 2004-06-16 Sivaiah Nallagatla * gui/contact-editor/e-contact-editor.c (full_name_clicked) : compare old and new full names and if it is different set the new the name using gtk_entry_set_text instead of set_entry_text as this function blocks siganls hence preventing ok button being enabled svn path=/trunk/; revision=26359 --- addressbook/ChangeLog | 8 ++++++++ addressbook/gui/contact-editor/e-contact-editor.c | 5 ++++- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/addressbook/ChangeLog b/addressbook/ChangeLog index deee273672..b2caf215b1 100644 --- a/addressbook/ChangeLog +++ b/addressbook/ChangeLog @@ -1,3 +1,11 @@ +2004-06-16 Sivaiah Nallagatla + + * gui/contact-editor/e-contact-editor.c (full_name_clicked) : + compare old and new full names and if it is different set the new + the name using gtk_entry_set_text instead of set_entry_text + as this function blocks siganls hence preventing ok button being + enabled + 2004-06-14 Chris Toshok * gui/contact-editor/e-contact-editor.c (extract_im_record): set diff --git a/addressbook/gui/contact-editor/e-contact-editor.c b/addressbook/gui/contact-editor/e-contact-editor.c index f9f1af9286..a09a263edd 100644 --- a/addressbook/gui/contact-editor/e-contact-editor.c +++ b/addressbook/gui/contact-editor/e-contact-editor.c @@ -2317,7 +2317,10 @@ full_name_clicked (GtkWidget *button, EContactEditor *editor) fname_widget = glade_xml_get_widget(editor->gui, "entry-fullname"); if (fname_widget && GTK_IS_ENTRY (fname_widget)) { char *full_name = e_contact_name_to_string(name); - set_entry_text (editor, GTK_ENTRY (fname_widget), full_name); + const char *old_full_name = gtk_entry_get_text (GTK_ENTRY(fname_widget)); + + if (strcmp (full_name, old_full_name)) + gtk_entry_set_text (GTK_ENTRY (fname_widget), full_name); g_free(full_name); } -- cgit v1.2.3