aboutsummaryrefslogtreecommitdiffstats
path: root/mail/message-thread.c
diff options
context:
space:
mode:
authorDan Winship <danw@src.gnome.org>2000-08-13 07:07:19 +0800
committerDan Winship <danw@src.gnome.org>2000-08-13 07:07:19 +0800
commit9178fed291ee57d90636be4f0ca69db80b61df4b (patch)
tree7a79aca62d1fb5b689524bba2377efd9b20e1fef /mail/message-thread.c
parent031bffff9cf122ac2014d364c249d7e894929bbc (diff)
downloadgsoc2013-evolution-9178fed291ee57d90636be4f0ca69db80b61df4b.tar
gsoc2013-evolution-9178fed291ee57d90636be4f0ca69db80b61df4b.tar.gz
gsoc2013-evolution-9178fed291ee57d90636be4f0ca69db80b61df4b.tar.bz2
gsoc2013-evolution-9178fed291ee57d90636be4f0ca69db80b61df4b.tar.lz
gsoc2013-evolution-9178fed291ee57d90636be4f0ca69db80b61df4b.tar.xz
gsoc2013-evolution-9178fed291ee57d90636be4f0ca69db80b61df4b.tar.zst
gsoc2013-evolution-9178fed291ee57d90636be4f0ca69db80b61df4b.zip
Don't clear the tree here. If two "folder_changed"s arrive in close
* message-list.c (cleanup_regenerate_messagelist): Don't clear the tree here. If two "folder_changed"s arrive in close succession, then one possible ordering of events is cleanup_regenerate_messagelist, cleanup_regenerate_messagelist, cleanup_thread_messages, cleanup_thread_messages. Which would result in the message list being filled in twice without being cleared in between. So don't clear it until the rebuilding function itself is called. (clear_tree): New function to empty out the ETreeModel in the message list. (build_tree): Change to simpler interface. Call clear_tree. (build_subtree): Does most of the work of the old build_tree (build_flat): Remove unused arg. Call clear_tree. * message-thread.c (cleanup_thread_messages): Update for build_tree interface change. svn path=/trunk/; revision=4787
Diffstat (limited to 'mail/message-thread.c')
-rw-r--r--mail/message-thread.c12
1 files changed, 4 insertions, 8 deletions
diff --git a/mail/message-thread.c b/mail/message-thread.c
index cb17a65c34..b703889670 100644
--- a/mail/message-thread.c
+++ b/mail/message-thread.c
@@ -509,13 +509,11 @@ typedef struct thread_messages_input_s {
MessageList *ml;
GPtrArray *uids;
gboolean use_camel_uidfree;
- void (*build) (MessageList *, ETreePath *,
- struct _container *, int *);
+ void (*build) (MessageList *, struct _container *);
} thread_messages_input_t;
typedef struct thread_messages_data_s {
struct _container *container;
- int row;
} thread_messages_data_t;
static gchar *describe_thread_messages (gpointer in_data, gboolean gerund);
@@ -562,7 +560,6 @@ static void do_thread_messages (gpointer in_data, gpointer op_data, CamelExcepti
thread_messages_data_t *data = (thread_messages_data_t *) op_data;
data->container = thread_messages (input->ml->folder, input->uids);
- data->row = 0;
}
static void cleanup_thread_messages (gpointer in_data, gpointer op_data, CamelException *ex)
@@ -570,8 +567,7 @@ static void cleanup_thread_messages (gpointer in_data, gpointer op_data, CamelEx
thread_messages_input_t *input = (thread_messages_input_t *) in_data;
thread_messages_data_t *data = (thread_messages_data_t *) op_data;
- (input->build) (input->ml, input->ml->tree_root,
- data->container, &(data->row));
+ (input->build) (input->ml, data->container);
thread_messages_free (data->container);
if (input->use_camel_uidfree) {
@@ -597,8 +593,8 @@ static const mail_operation_spec op_thread_messages =
void mail_do_thread_messages (MessageList *ml, GPtrArray *uids,
gboolean use_camel_uidfree,
- void (*build) (MessageList *, ETreePath *,
- struct _container *, int *))
+ void (*build) (MessageList *,
+ struct _container *))
{
thread_messages_input_t *input;