[evolution] Make em_utils_in_addressbook() cancellable
- From: Dan VrÃtil <dvratil src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution] Make em_utils_in_addressbook() cancellable
- Date: Thu, 14 Jun 2012 11:02:22 +0000 (UTC)
commit e439e17e2e14fc5a3a35924dddfdd4d8602c3d8c
Author: Dan VrÃtil <dvratil redhat com>
Date: Thu Jun 14 13:01:57 2012 +0200
Make em_utils_in_addressbook() cancellable
libemail-engine/e-mail-session.c | 2 +-
libemail-engine/e-mail-utils.c | 5 +++--
libemail-engine/e-mail-utils.h | 3 ++-
mail/e-http-request.c | 2 +-
4 files changed, 7 insertions(+), 5 deletions(-)
---
diff --git a/libemail-engine/e-mail-session.c b/libemail-engine/e-mail-session.c
index a319a88..4b4cdf2 100644
--- a/libemail-engine/e-mail-session.c
+++ b/libemail-engine/e-mail-session.c
@@ -1329,7 +1329,7 @@ mail_session_lookup_addressbook (CamelSession *session,
addr = camel_internet_address_new ();
camel_address_decode ((CamelAddress *) addr, name);
ret = em_utils_in_addressbook (
- registry, addr, mail_config_get_lookup_book_local_only ());
+ registry, addr, mail_config_get_lookup_book_local_only (), NULL);
g_object_unref (addr);
return ret;
diff --git a/libemail-engine/e-mail-utils.c b/libemail-engine/e-mail-utils.c
index 7fca5eb..964de98 100644
--- a/libemail-engine/e-mail-utils.c
+++ b/libemail-engine/e-mail-utils.c
@@ -600,7 +600,8 @@ search_address_in_addressbooks (ESourceRegistry *registry,
gboolean
em_utils_in_addressbook (ESourceRegistry *registry,
CamelInternetAddress *iaddr,
- gboolean local_only)
+ gboolean local_only,
+ GCancellable *cancellable)
{
const gchar *addr;
@@ -611,7 +612,7 @@ em_utils_in_addressbook (ESourceRegistry *registry,
return FALSE;
return search_address_in_addressbooks (
- registry, addr, local_only, NULL, NULL, NULL);
+ registry, addr, local_only, NULL, NULL, cancellable);
}
static gboolean
diff --git a/libemail-engine/e-mail-utils.h b/libemail-engine/e-mail-utils.h
index 8898204..812dde2 100644
--- a/libemail-engine/e-mail-utils.h
+++ b/libemail-engine/e-mail-utils.h
@@ -35,7 +35,8 @@ gboolean em_utils_folder_is_outbox (ESourceRegistry *registry,
CamelFolder *folder);
gboolean em_utils_in_addressbook (ESourceRegistry *registry,
CamelInternetAddress *addr,
- gboolean local_only);
+ gboolean local_only,
+ GCancellable *cancellable);
CamelMimePart * em_utils_contact_photo (ESourceRegistry *registry,
CamelInternetAddress *addr,
gboolean local,
diff --git a/mail/e-http-request.c b/mail/e-http-request.c
index 95a97e6..f5fd12f 100644
--- a/mail/e-http-request.c
+++ b/mail/e-http-request.c
@@ -340,7 +340,7 @@ handle_http_request (GSimpleAsyncResult *res,
registry = e_shell_get_registry (shell);
addr = camel_mime_message_get_from (part_list->message);
force_load_images = em_utils_in_addressbook (
- registry, addr, FALSE);
+ registry, addr, FALSE, cancellable);
}
g_free (decoded_uri);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]