aboutsummaryrefslogtreecommitdiffstats
path: root/addressbook/backend/ebook/evolution-ldif-importer.c
diff options
context:
space:
mode:
authorChris Toshok <toshok@ximian.com>2003-03-27 13:21:18 +0800
committerChris Toshok <toshok@src.gnome.org>2003-03-27 13:21:18 +0800
commitcd51875a54f1e77fb433a9b90277047dc580608f (patch)
tree4e9de6f9c1d89596e6b8766bddca185942029fe1 /addressbook/backend/ebook/evolution-ldif-importer.c
parent15f4e1e0abee33191587d78041af3787cf47ebf2 (diff)
downloadgsoc2013-evolution-cd51875a54f1e77fb433a9b90277047dc580608f.tar
gsoc2013-evolution-cd51875a54f1e77fb433a9b90277047dc580608f.tar.gz
gsoc2013-evolution-cd51875a54f1e77fb433a9b90277047dc580608f.tar.bz2
gsoc2013-evolution-cd51875a54f1e77fb433a9b90277047dc580608f.tar.lz
gsoc2013-evolution-cd51875a54f1e77fb433a9b90277047dc580608f.tar.xz
gsoc2013-evolution-cd51875a54f1e77fb433a9b90277047dc580608f.tar.zst
gsoc2013-evolution-cd51875a54f1e77fb433a9b90277047dc580608f.zip
[ fixes bug #19178 ] use e_book_load_address_book_by_uri on the passed in
2003-03-26 Chris Toshok <toshok@ximian.com> [ fixes bug #19178 ] * backend/ebook/evolution-ldif-importer.c (ebook_open): use e_book_load_address_book_by_uri on the passed in uri. (load_file_fn): pass the uri. * backend/ebook/evolution-vcard-importer.c (ebook_open): use e_book_load_address_book_by_uri on the passed in uri. (load_file_fn): pass the uri. svn path=/trunk/; revision=20543
Diffstat (limited to 'addressbook/backend/ebook/evolution-ldif-importer.c')
-rw-r--r--addressbook/backend/ebook/evolution-ldif-importer.c21
1 files changed, 4 insertions, 17 deletions
diff --git a/addressbook/backend/ebook/evolution-ldif-importer.c b/addressbook/backend/ebook/evolution-ldif-importer.c
index 08740558c4..7a204daa95 100644
--- a/addressbook/backend/ebook/evolution-ldif-importer.c
+++ b/addressbook/backend/ebook/evolution-ldif-importer.c
@@ -450,12 +450,8 @@ book_open_cb (EBook *book, EBookStatus status, gpointer closure)
}
static void
-ebook_create (LDIFImporter *gci)
+ebook_open (LDIFImporter *gci, const char *uri)
{
-#if 0
- gchar *path, *uri;
-#endif
-
gci->book = e_book_new ();
if (!gci->book) {
@@ -464,17 +460,8 @@ ebook_create (LDIFImporter *gci)
G_GNUC_FUNCTION);
return;
}
-#if 0
- path = g_concat_dir_and_file (g_get_home_dir (),
- "evolution/local/Contacts/addressbook.db");
- uri = g_strdup_printf ("file://%s", path);
- g_free (path);
-
- e_book_load_uri (gci->book, uri, book_open_cb, gci);
- g_free(uri);
-#endif
- e_book_load_default_book (gci->book, book_open_cb, gci);
+ e_book_load_address_book_by_uri (gci->book, uri, book_open_cb, gci);
}
/* EvolutionImporter methods */
@@ -558,7 +545,7 @@ importer_destroy_cb (gpointer data,
static gboolean
load_file_fn (EvolutionImporter *importer,
const char *filename,
- const char *folderpath,
+ const char *uri,
void *closure)
{
LDIFImporter *gci;
@@ -568,7 +555,7 @@ load_file_fn (EvolutionImporter *importer,
gci->cardlist = NULL;
gci->iterator = NULL;
gci->ready = FALSE;
- ebook_create (gci);
+ ebook_open (gci, uri);
return TRUE;
}