aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--addressbook/ChangeLog7
-rw-r--r--addressbook/gui/contact-editor/e-contact-quick-add.c15
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