aboutsummaryrefslogtreecommitdiffstats
path: root/mail/message-list.c
diff options
context:
space:
mode:
author9 <NotZed@Ximian.com>2001-09-19 16:29:13 +0800
committerMichael Zucci <zucchi@src.gnome.org>2001-09-19 16:29:13 +0800
commit73c74dd70d7e023cc24f7e28d52417b3c4e72805 (patch)
tree79596aab616dd7f2abd55c6f6a86c1abb3687d76 /mail/message-list.c
parentbef39dc4e0bbdb334fef71f973bcb7781dce65df (diff)
downloadgsoc2013-evolution-73c74dd70d7e023cc24f7e28d52417b3c4e72805.tar
gsoc2013-evolution-73c74dd70d7e023cc24f7e28d52417b3c4e72805.tar.gz
gsoc2013-evolution-73c74dd70d7e023cc24f7e28d52417b3c4e72805.tar.bz2
gsoc2013-evolution-73c74dd70d7e023cc24f7e28d52417b3c4e72805.tar.lz
gsoc2013-evolution-73c74dd70d7e023cc24f7e28d52417b3c4e72805.tar.xz
gsoc2013-evolution-73c74dd70d7e023cc24f7e28d52417b3c4e72805.tar.zst
gsoc2013-evolution-73c74dd70d7e023cc24f7e28d52417b3c4e72805.zip
General cleanup of mail debug printfs.
2001-09-19 <NotZed@Ximian.com> * General cleanup of mail debug printfs. * mail-folder-cache.[ch]: Completely rewritten. Removed all calls to the old code everywhere they were used. Nuff said. * folder-browser.h: Add shell_view to folder_browser & api to set it. * folder-browser-factory.c (control_activate): Set the shell-view on the folder_browser. (control_deactivate): And clear it here. * folder-browser.c (folder_browser_destroy): Unhook from changed events on the folder before giving it away. (got_folder): Hook onto the folder-changed events. (folder_changed): Event hook proxy for folder_changed events (main_folder_changed): And the main code version. (update_status_bar): And the one that actually does the work. (on_selection_changed): Also call update_status_bar() to update the selection count. (folder_browser_set_shell_view): Implement function to set the shell_view on the folder_browser. (folder_browser_destroy): Release the shell_view here too. * mail-tools.c (mail_tool_uri_to_folder): Dont 'note' the new folder if its from a file: url, this is handled by hte local store (yeeruughck). * mail-local.c (mls_init): (free_info): (mls_finalise): Setup init/finalise funcs for the folderinfo hash. (local_storage_removed_folder_cb): re-enable. 2001-09-18 <NotZed@Ximian.com> * mail-local.c (MailLocalStore): Add a hash table to store uri<>folderinfo data. (mail_local_store_add_folder): Add a new folderinfo to our hash. (mail_local_store_remove_folder): Remove a folder by uri. (storage_listener_startup): Add this store to those monitored by the folder tree. svn path=/trunk/; revision=12974
Diffstat (limited to 'mail/message-list.c')
-rw-r--r--mail/message-list.c21
1 files changed, 18 insertions, 3 deletions
diff --git a/mail/message-list.c b/mail/message-list.c
index f91f5ce5ac..1dcd49bc48 100644
--- a/mail/message-list.c
+++ b/mail/message-list.c
@@ -1812,10 +1812,10 @@ main_folder_changed (CamelObject *o, gpointer event_data, gpointer user_data)
CamelFolder *folder = (CamelFolder *)o;
int i;
- printf("folder changed event, changes = %p\n", changes);
+ d(printf("folder changed event, changes = %p\n", changes));
if (changes) {
- printf("changed = %d added = %d removed = %d\n",
- changes->uid_changed->len, changes->uid_added->len, changes->uid_removed->len);
+ d(printf("changed = %d added = %d removed = %d\n",
+ changes->uid_changed->len, changes->uid_added->len, changes->uid_removed->len));
/* check if the hidden state has changed, if so modify accordingly, then regenerate */
if (ml->hidedeleted) {
@@ -2129,6 +2129,21 @@ message_list_length (MessageList *ml)
return ml->hide_unhidden;
}
+/* returns number of hidden messages */
+unsigned int
+message_list_hidden(MessageList *ml)
+{
+ unsigned int hidden = 0;
+
+ MESSAGE_LIST_LOCK (ml, hide_lock);
+ if (ml->hidden)
+ hidden = g_hash_table_size (ml->hidden);
+ MESSAGE_LIST_UNLOCK (ml, hide_lock);
+
+ return hidden;
+}
+
+
/* add a new expression to hide, or set the range.
@expr: A new search expression - all matching messages will be hidden. May be %NULL.
@lower: Use ML_HIDE_NONE_START to specify no messages hidden from the start of the list.