From 58084b908ae3b3cdf0cb65137d8825007086ffb5 Mon Sep 17 00:00:00 2001 From: Dan Winship Date: Mon, 19 Aug 2002 19:31:59 +0000 Subject: add an "addresses" property, to get the "Dan Winship " * gui/component/select-names/e-select-names-bonobo.c (entry_get_property_fn): add an "addresses" property, to get the "Dan Winship " form, as opposed to "text", which gets you what's displayed, which might be just "Dan Winship". (entry_set_property_fn): When setting, just reuse the "text" code, since it should properly cardify everything for us anyway. (impl_SelectNames_get_entry_for_section): Add the property. svn path=/trunk/; revision=17803 --- addressbook/ChangeLog | 10 ++++++++++ .../component/select-names/e-select-names-bonobo.c | 19 +++++++++++++++++++ 2 files changed, 29 insertions(+) (limited to 'addressbook') diff --git a/addressbook/ChangeLog b/addressbook/ChangeLog index 410ebb1e95..a92016d810 100644 --- a/addressbook/ChangeLog +++ b/addressbook/ChangeLog @@ -1,3 +1,13 @@ +2002-08-19 Dan Winship + + * gui/component/select-names/e-select-names-bonobo.c + (entry_get_property_fn): add an "addresses" property, to get the + "Dan Winship " form, as opposed to "text", which + gets you what's displayed, which might be just "Dan Winship". + (entry_set_property_fn): When setting, just reuse the "text" code, + since it should properly cardify everything for us anyway. + (impl_SelectNames_get_entry_for_section): Add the property. + 2002-08-16 Chris Toshok * gui/component/addressbook-config.c diff --git a/addressbook/gui/component/select-names/e-select-names-bonobo.c b/addressbook/gui/component/select-names/e-select-names-bonobo.c index 95fc4bc262..4a32790cd4 100644 --- a/addressbook/gui/component/select-names/e-select-names-bonobo.c +++ b/addressbook/gui/component/select-names/e-select-names-bonobo.c @@ -53,6 +53,7 @@ struct _ESelectNamesBonoboPrivate { enum _EntryPropertyID { ENTRY_PROPERTY_ID_TEXT, + ENTRY_PROPERTY_ID_ADDRESSES, ENTRY_PROPERTY_ID_DESTINATIONS, ENTRY_PROPERTY_ID_SIMPLE_CARD_LIST, ENTRY_PROPERTY_ID_ALLOW_CONTACT_LISTS, @@ -85,6 +86,20 @@ entry_get_property_fn (BonoboPropertyBag *bag, break; } + case ENTRY_PROPERTY_ID_ADDRESSES: + { + ESelectNamesModel *model; + char *text; + + model = E_SELECT_NAMES_MODEL (gtk_object_get_data (GTK_OBJECT (w), "select_names_model")); + g_assert (model != NULL); + + text = e_select_names_model_get_address_text (model, ", "); + BONOBO_ARG_SET_STRING (arg, text); + g_free (text); + } + break; + case ENTRY_PROPERTY_ID_DESTINATIONS: { ESelectNamesModel *model; @@ -165,6 +180,7 @@ entry_set_property_fn (BonoboPropertyBag *bag, switch (arg_id) { case ENTRY_PROPERTY_ID_TEXT: + case ENTRY_PROPERTY_ID_ADDRESSES: { ESelectNamesModel *model; model = E_SELECT_NAMES_MODEL (gtk_object_get_data (GTK_OBJECT (w), "select_names_model")); @@ -346,6 +362,9 @@ impl_SelectNames_get_entry_for_section (PortableServer_Servant servant, bonobo_property_bag_add (property_bag, "text", ENTRY_PROPERTY_ID_TEXT, BONOBO_ARG_STRING, NULL, NULL, BONOBO_PROPERTY_READABLE | BONOBO_PROPERTY_WRITEABLE); + bonobo_property_bag_add (property_bag, "addresses", ENTRY_PROPERTY_ID_ADDRESSES, + BONOBO_ARG_STRING, NULL, NULL, + BONOBO_PROPERTY_READABLE | BONOBO_PROPERTY_WRITEABLE); bonobo_property_bag_add (property_bag, "destinations", ENTRY_PROPERTY_ID_DESTINATIONS, BONOBO_ARG_STRING, NULL, NULL, BONOBO_PROPERTY_READABLE | BONOBO_PROPERTY_WRITEABLE); -- cgit