From 8e9818c86f559fee079fb6752e9a7c61e2591453 Mon Sep 17 00:00:00 2001 From: Chris Toshok Date: Sun, 26 Mar 2000 07:55:32 +0000 Subject: create a card and then look it up. * addressbook/backend/ebook/test-client.c: create a card and then look it up. svn path=/trunk/; revision=2168 --- addressbook/backend/ebook/test-client.c | 32 +++++++++++++++++++++++++++++++- 1 file changed, 31 insertions(+), 1 deletion(-) (limited to 'addressbook/backend') diff --git a/addressbook/backend/ebook/test-client.c b/addressbook/backend/ebook/test-client.c index 074709aef7..dce7e7fc87 100644 --- a/addressbook/backend/ebook/test-client.c +++ b/addressbook/backend/ebook/test-client.c @@ -5,6 +5,30 @@ #include +#define TEST_VCARD \ +"BEGIN:VCARD +" \ +"FN:Nat +" \ +"N:Friedman;Nat;D;Mr. +" \ +"BDAY:1977-08-06 +" \ +"TEL;WORK:617 679 1984 +" \ +"TEL;CELL:123 456 7890 +" \ +"EMAIL;INTERNET:nat@nat.org +" \ +"EMAIL;INTERNET:nat@helixcode.com +" \ +"ADR;WORK;POSTAL:P.O. Box 101;;;Any Town;CA;91921-1234; +" \ +"END:VCARD +" \ +" +" + CORBA_Environment ev; CORBA_ORB orb; @@ -24,7 +48,7 @@ init_bonobo (int argc, char **argv) } static void -book_open_cb (EBook *book, EBookStatus status, gpointer closure) +add_card_cb (EBook *book, EBookStatus status, gpointer closure) { char *vcard; GTimer *timer; @@ -40,6 +64,12 @@ book_open_cb (EBook *book, EBookStatus status, gpointer closure) printf ("[%s]\n", vcard); } +static void +book_open_cb (EBook *book, EBookStatus status, gpointer closure) +{ + e_book_add_vcard(book, TEST_VCARD, add_card_cb, NULL); +} + static guint ebook_create (void) { -- cgit v1.2.3