aboutsummaryrefslogtreecommitdiffstats
path: root/addressbook/backend/ebook/e-book-listener.c
diff options
context:
space:
mode:
authorChris Toshok <toshok@ximian.com>2001-03-02 18:39:16 +0800
committerChris Toshok <toshok@src.gnome.org>2001-03-02 18:39:16 +0800
commit3e7e23772816efd672b314bcf507609cea821dd5 (patch)
tree32c3e2ab95293ae171eaa1cb58c2fb9b589846f1 /addressbook/backend/ebook/e-book-listener.c
parentdeec95c6d5c7e7ac6e4fab24cfa1b05f4283be68 (diff)
downloadgsoc2013-evolution-3e7e23772816efd672b314bcf507609cea821dd5.tar
gsoc2013-evolution-3e7e23772816efd672b314bcf507609cea821dd5.tar.gz
gsoc2013-evolution-3e7e23772816efd672b314bcf507609cea821dd5.tar.bz2
gsoc2013-evolution-3e7e23772816efd672b314bcf507609cea821dd5.tar.lz
gsoc2013-evolution-3e7e23772816efd672b314bcf507609cea821dd5.tar.xz
gsoc2013-evolution-3e7e23772816efd672b314bcf507609cea821dd5.tar.zst
gsoc2013-evolution-3e7e23772816efd672b314bcf507609cea821dd5.zip
add new entries for phone enums, and fill in the ecard_field with (bogus
2001-03-02 Chris Toshok <toshok@ximian.com> * backend/ebook/e-card-simple.c (field_data): add new entries for phone enums, and fill in the ecard_field with (bogus in all but a few cases) strings. these are the strings sent from wombat to evolution-addressbook for supported_fields. (e_card_simple_get_ecard_field): new function. (e_card_simple_map_phone_to_field): new function. (e_card_simple_map_email_to_field): new function. (e_card_simple_map_address_to_field): new function. * backend/ebook/e-card-simple.h: add a few phone entries to the ECardSimpleField enum, and add prototypes for mapping the list types (phone, email, address) to ECardSimpleField. Also, add prototype for e_card_simple_get_ecard_field. * backend/ebook/e-book.c (e_book_do_response_get_supported_fields): don't build the EList here, it's already built. * backend/ebook/e-book-listener.h: change fields from the CORBA sequence to the EList in our reponse struct. * backend/ebook/e-book-listener.c (e_book_listener_queue_get_supported_fields_response): we make the EList here, since after we return the CORBA list is freed up. svn path=/trunk/; revision=8515
Diffstat (limited to 'addressbook/backend/ebook/e-book-listener.c')
-rw-r--r--addressbook/backend/ebook/e-book-listener.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/addressbook/backend/ebook/e-book-listener.c b/addressbook/backend/ebook/e-book-listener.c
index 8ef9072bf6..0aaf5483a5 100644
--- a/addressbook/backend/ebook/e-book-listener.c
+++ b/addressbook/backend/ebook/e-book-listener.c
@@ -207,12 +207,17 @@ e_book_listener_queue_get_supported_fields_response (EBookListener *listener,
const GNOME_Evolution_Addressbook_stringlist *fields)
{
EBookListenerResponse *resp;
+ int i;
resp = g_new0 (EBookListenerResponse, 1);
resp->op = GetSupportedFieldsResponse;
resp->status = status;
- resp->fields = fields;
+ resp->fields = e_list_new ((EListCopyFunc)g_strdup, (EListFreeFunc)g_free, NULL);
+
+ for (i = 0; i < fields->_length; i ++) {
+ e_list_append (resp->fields, g_strdup (fields->_buffer[i]));
+ }
e_book_listener_queue_response (listener, resp);
}