Lines 29-35
Link Here
|
29 |
|
29 |
|
30 |
#include "merge-evolution.h" |
30 |
#include "merge-evolution.h" |
31 |
|
31 |
|
32 |
#include <libebook/e-book.h> |
32 |
#include <libebook/libebook.h> |
33 |
#include <glib/gi18n.h> |
33 |
#include <glib/gi18n.h> |
34 |
#include <stdio.h> |
34 |
#include <stdio.h> |
35 |
#include <string.h> |
35 |
#include <string.h> |
Lines 302-307
gl_merge_evolution_open (glMerge *merge)
Link Here
|
302 |
{ |
302 |
{ |
303 |
glMergeEvolution *merge_evolution; |
303 |
glMergeEvolution *merge_evolution; |
304 |
EBookQuery *query; |
304 |
EBookQuery *query; |
|
|
305 |
ESourceRegistry *registry; |
306 |
ESource *source; |
305 |
gboolean status; |
307 |
gboolean status; |
306 |
GList *fields, *iter; |
308 |
GList *fields, *iter; |
307 |
EContactField *field_id; |
309 |
EContactField *field_id; |
Lines 317-323
gl_merge_evolution_open (glMerge *merge)
Link Here
|
317 |
return; |
319 |
return; |
318 |
} |
320 |
} |
319 |
|
321 |
|
320 |
merge_evolution->priv->book = e_book_new_system_addressbook(&error); |
322 |
registry = e_source_registry_new_sync(NULL, &error); |
|
|
323 |
if (!registry) { |
324 |
g_warning ("Couldn't open registry."); |
325 |
if (error) |
326 |
{ |
327 |
g_warning ("e_source_registry_new_sync: %s", error->message); |
328 |
g_error_free (error); |
329 |
} |
330 |
e_book_query_unref(query); |
331 |
return; |
332 |
} |
333 |
|
334 |
source = e_source_registry_ref_default_address_book(registry); |
335 |
g_object_unref(registry); |
336 |
|
337 |
merge_evolution->priv->book = e_book_new(source, &error); |
338 |
g_object_unref(source); |
321 |
if (!merge_evolution->priv->book) { |
339 |
if (!merge_evolution->priv->book) { |
322 |
g_warning ("Couldn't open addressbook."); |
340 |
g_warning ("Couldn't open addressbook."); |
323 |
if (error) |
341 |
if (error) |