From 88b02e9cf481aee0762f7e7bc0b32032cdfeb899 Mon Sep 17 00:00:00 2001 From: Not Zed Date: Thu, 11 Mar 2004 03:05:43 +0000 Subject: pass the raw header in instead of name and value. (efh_format_headers): if 2004-03-11 Not Zed * em-format-html.c (efh_format_header): pass the raw header in instead of name and value. (efh_format_headers): if we have specific headers to show, iterate over all headers and print out all matching ones, so duplicate headers are properly displayed. Related to #55298. * em-folder-selector.c (em_folder_selector_construct): dont set this to be modal. otherwise you can't click on error popups. duh. 2004-03-08 Not Zed * em-folder-selection-button.c (em_folder_selection_button_clicked): don't let the user select virtual/vtrash folders or non-selectable folders. * mail-component.c (impl_createControls): disable selection of non-select rows. * em-folder-selector.c (em_folder_selector_create_new): exclude folders with noinferiors set. * em-folder-tree.c (folder_tree_new): add folder tree arg, hook onto the selection funciton for the tree selection. (emft_select_func): selection override function. allow certain things to be excluded. (em_folder_tree_set_excluded): api to set what is excluded from the selectability. (emft_tree_row_activated): call emft_select_func check to see if this row is excluded before emitting an activated signal. * em-folder-tree-model.c (em_folder_tree_model_set_folder_info): save folder info->flags in the tree store. * mail-folder-cache.c (create_folders): use tail recursion. (get_folders): tail recurse. * (*): Fixed for api changes in camel. svn path=/trunk/; revision=25020 --- mail/em-folder-tree-model.c | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) (limited to 'mail/em-folder-tree-model.c') diff --git a/mail/em-folder-tree-model.c b/mail/em-folder-tree-model.c index a095a88da6..62b526496a 100644 --- a/mail/em-folder-tree-model.c +++ b/mail/em-folder-tree-model.c @@ -59,6 +59,7 @@ static GType col_types[] = { G_TYPE_STRING, /* path */ G_TYPE_STRING, /* uri */ G_TYPE_UINT, /* unread count */ + G_TYPE_UINT, /* flags */ G_TYPE_BOOLEAN, /* is a store node */ G_TYPE_BOOLEAN, /* has not-yet-loaded subfolders */ }; @@ -433,13 +434,13 @@ em_folder_tree_model_set_folder_info (EMFolderTreeModel *model, GtkTreeIter *ite path_row = gtk_tree_row_reference_copy (uri_row); gtk_tree_path_free (path); - g_hash_table_insert (model->uri_hash, g_strdup (fi->url), uri_row); + g_hash_table_insert (model->uri_hash, g_strdup (fi->uri), uri_row); g_hash_table_insert (si->path_hash, g_strdup (fi->path), path_row); /* HACK: if we have the folder, and its the outbox folder, we need the total count, not unread */ /* This is duplicated in mail-folder-cache too, should perhaps be functionised */ - unread = fi->unread_message_count == -1 ? 0 : fi->unread_message_count; - if (mail_note_get_folder_from_uri(fi->url, &folder) && folder) { + unread = fi->unread == -1 ? 0 : fi->unread; + if (mail_note_get_folder_from_uri(fi->uri, &folder) && folder) { if (folder == mail_component_get_folder(NULL, MAIL_COMPONENT_FOLDER_OUTBOX)) unread = camel_folder_get_message_count(folder); camel_object_unref(folder); @@ -449,8 +450,9 @@ em_folder_tree_model_set_folder_info (EMFolderTreeModel *model, GtkTreeIter *ite COL_STRING_DISPLAY_NAME, fi->name, COL_POINTER_CAMEL_STORE, si->store, COL_STRING_FOLDER_PATH, fi->path, - COL_STRING_URI, fi->url, + COL_STRING_URI, fi->uri, COL_UINT_UNREAD, unread, + COL_UINT_FLAGS, fi->flags, COL_BOOL_IS_STORE, FALSE, COL_BOOL_LOAD_SUBDIRS, load, -1); @@ -461,7 +463,7 @@ em_folder_tree_model_set_folder_info (EMFolderTreeModel *model, GtkTreeIter *ite do { gtk_tree_store_append ((GtkTreeStore *) model, &sub, iter); em_folder_tree_model_set_folder_info (model, &sub, si, fi); - fi = fi->sibling; + fi = fi->next; } while (fi); } else if (load) { /* create a placeholder node for our subfolders... */ @@ -537,7 +539,7 @@ folder_subscribed (CamelStore *store, CamelFolderInfo *fi, EMFolderTreeModel *mo em_folder_tree_model_set_folder_info (model, &iter, si, fi); - g_signal_emit (model, signals[FOLDER_ADDED], 0, fi->path, fi->url); + g_signal_emit (model, signals[FOLDER_ADDED], 0, fi->path, fi->uri); done: -- cgit