diff options
author | Chris Toshok <toshok@ximian.com> | 2002-09-12 08:14:11 +0800 |
---|---|---|
committer | Chris Toshok <toshok@src.gnome.org> | 2002-09-12 08:14:11 +0800 |
commit | c2160221e6d637a14f6e335366e8a8c00fbfa7f3 (patch) | |
tree | 7c1cb51fab25423460d7786a7f6d5be24e95f072 /addressbook | |
parent | 97c238ccd969e4945c37770f904b169c9d3248d0 (diff) | |
download | gsoc2013-evolution-c2160221e6d637a14f6e335366e8a8c00fbfa7f3.tar.gz gsoc2013-evolution-c2160221e6d637a14f6e335366e8a8c00fbfa7f3.tar.zst gsoc2013-evolution-c2160221e6d637a14f6e335366e8a8c00fbfa7f3.zip |
[ fixes the other half of #17336 ] parse the name when we're asked to set
2002-09-11 Chris Toshok <toshok@ximian.com>
[ fixes the other half of #17336 ]
* gui/contact-editor/e-contact-quick-add.c (quick_add_set_name):
parse the name when we're asked to set it, so the full name
doesn't get stored as (potentially) "Last, First" in the card.
svn path=/trunk/; revision=18051
Diffstat (limited to 'addressbook')
-rw-r--r-- | addressbook/ChangeLog | 7 | ||||
-rw-r--r-- | addressbook/gui/contact-editor/e-contact-quick-add.c | 15 |
2 files changed, 16 insertions, 6 deletions
diff --git a/addressbook/ChangeLog b/addressbook/ChangeLog index 0e199f04b1..d9b421a0f4 100644 --- a/addressbook/ChangeLog +++ b/addressbook/ChangeLog @@ -1,5 +1,12 @@ 2002-09-11 Chris Toshok <toshok@ximian.com> + [ fixes the other half of #17336 ] + * gui/contact-editor/e-contact-quick-add.c (quick_add_set_name): + parse the name when we're asked to set it, so the full name + doesn't get stored as (potentially) "Last, First" in the card. + +2002-09-11 Chris Toshok <toshok@ximian.com> + [ fixes part of #17336 ] * gui/contact-editor/e-contact-editor-fullname.c (e_contact_editor_fullname_init): get the window title from the diff --git a/addressbook/gui/contact-editor/e-contact-quick-add.c b/addressbook/gui/contact-editor/e-contact-quick-add.c index f36d0b101e..80687e1e0a 100644 --- a/addressbook/gui/contact-editor/e-contact-quick-add.c +++ b/addressbook/gui/contact-editor/e-contact-quick-add.c @@ -94,18 +94,21 @@ quick_add_unref (QuickAdd *qa) static void quick_add_set_name (QuickAdd *qa, const gchar *name) { - ECardSimple *simple; + ECardName *card_name; if (name == qa->name) return; g_free (qa->name); - qa->name = g_strdup (name); - simple = e_card_simple_new (qa->card); - e_card_simple_set (simple, E_CARD_SIMPLE_FIELD_FULL_NAME, name); - e_card_simple_sync_card (simple); - gtk_object_unref (GTK_OBJECT (simple)); + card_name = e_card_name_from_string (name); + qa->name = e_card_name_to_string (card_name); + + gtk_object_set (GTK_OBJECT (qa->card), + "full_name", qa->name, + NULL); + + e_card_name_unref (card_name); } static void |