[evolution-mapi] Bug #672175 - Make CamelFolderSearch cancellable
- From: Milan Crha <mcrha src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution-mapi] Bug #672175 - Make CamelFolderSearch cancellable
- Date: Tue, 27 Mar 2012 15:17:08 +0000 (UTC)
commit fe725a7118cdefb57a238d539f916a0ef65ab142
Author: Milan Crha <mcrha redhat com>
Date: Tue Mar 27 17:16:48 2012 +0200
Bug #672175 - Make CamelFolderSearch cancellable
src/camel/camel-mapi-folder.c | 15 +++++++++++----
1 files changed, 11 insertions(+), 4 deletions(-)
---
diff --git a/src/camel/camel-mapi-folder.c b/src/camel/camel-mapi-folder.c
index 1e13e2b..309f72b 100644
--- a/src/camel/camel-mapi-folder.c
+++ b/src/camel/camel-mapi-folder.c
@@ -99,21 +99,28 @@ static gboolean mapi_folder_synchronize_sync
G_DEFINE_TYPE (CamelMapiFolder, camel_mapi_folder, CAMEL_TYPE_OFFLINE_FOLDER)
static GPtrArray *
-mapi_folder_search_by_expression (CamelFolder *folder, const gchar *expression, GError **error)
+mapi_folder_search_by_expression (CamelFolder *folder,
+ const gchar *expression,
+ GCancellable *cancellable,
+ GError **error)
{
CamelMapiFolder *mapi_folder = CAMEL_MAPI_FOLDER(folder);
GPtrArray *matches;
CAMEL_MAPI_FOLDER_LOCK(mapi_folder, search_lock);
camel_folder_search_set_folder (mapi_folder->search, folder);
- matches = camel_folder_search_search(mapi_folder->search, expression, NULL, error);
+ matches = camel_folder_search_search(mapi_folder->search, expression, NULL, cancellable, error);
CAMEL_MAPI_FOLDER_UNLOCK(mapi_folder, search_lock);
return matches;
}
static GPtrArray *
-mapi_folder_search_by_uids (CamelFolder *folder, const gchar *expression, GPtrArray *uids, GError **error)
+mapi_folder_search_by_uids (CamelFolder *folder,
+ const gchar *expression,
+ GPtrArray *uids,
+ GCancellable *cancellable,
+ GError **error)
{
GPtrArray *matches;
CamelMapiFolder *mapi_folder = CAMEL_MAPI_FOLDER (folder);
@@ -123,7 +130,7 @@ mapi_folder_search_by_uids (CamelFolder *folder, const gchar *expression, GPtrAr
CAMEL_MAPI_FOLDER_LOCK (mapi_folder, search_lock);
camel_folder_search_set_folder (mapi_folder->search, folder);
- matches = camel_folder_search_search (mapi_folder->search, expression, uids, error);
+ matches = camel_folder_search_search (mapi_folder->search, expression, uids, cancellable, error);
CAMEL_MAPI_FOLDER_UNLOCK (mapi_folder, search_lock);
return matches;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]