aboutsummaryrefslogtreecommitdiffstats
path: root/addressbook/backend/ebook
diff options
context:
space:
mode:
authorChris Toshok <toshok@src.gnome.org>2000-03-26 15:55:32 +0800
committerChris Toshok <toshok@src.gnome.org>2000-03-26 15:55:32 +0800
commit8e9818c86f559fee079fb6752e9a7c61e2591453 (patch)
tree066a0415c463330175ce02e01d5c0eba03aa4c04 /addressbook/backend/ebook
parent0275405513ce108f32cd11f5f69c70fd2853427f (diff)
downloadgsoc2013-evolution-8e9818c86f559fee079fb6752e9a7c61e2591453.tar.gz
gsoc2013-evolution-8e9818c86f559fee079fb6752e9a7c61e2591453.tar.zst
gsoc2013-evolution-8e9818c86f559fee079fb6752e9a7c61e2591453.zip
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
Diffstat (limited to 'addressbook/backend/ebook')
-rw-r--r--addressbook/backend/ebook/test-client.c32
1 files changed, 31 insertions, 1 deletions
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 <e-book.h>
+#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)
{