[Commits] prefs_folder_item.c 1.52.2.85 1.52.2.86
pawel at claws-mail.org
pawel at claws-mail.org
Sun Oct 30 20:34:45 CET 2011
Update of /home/claws-mail/claws/src
In directory claws-mail:/tmp/cvs-serv5229/src
Modified Files:
Tag: gtk2
prefs_folder_item.c
Log Message:
2011-10-30 [pawel] 3.7.10cvs59
* src/prefs_folder_item.c
Update summaryview after changing folder prefs when needed
Index: prefs_folder_item.c
===================================================================
RCS file: /home/claws-mail/claws/src/prefs_folder_item.c,v
retrieving revision 1.52.2.85
retrieving revision 1.52.2.86
diff -u -d -r1.52.2.85 -r1.52.2.86
--- prefs_folder_item.c 22 Oct 2011 17:09:03 -0000 1.52.2.85
+++ prefs_folder_item.c 30 Oct 2011 19:34:43 -0000 1.52.2.86
@@ -628,8 +628,9 @@
{
FolderItemPrefs *prefs = folder->prefs;
gchar *buf;
- gboolean all = FALSE;
+ gboolean all = FALSE, summary_update_needed = FALSE;
SpecialFolderItemType type = F_NORMAL;
+ FolderView *folderview = mainwindow_get_mainwindow()->folderview;
if (folder->path == NULL)
return;
@@ -642,14 +643,20 @@
type = combobox_get_active_data(GTK_COMBO_BOX(page->folder_type));
if (all && folder->stype != type && page->item->parent_stype == F_NORMAL) {
folder_item_change_type(folder, type);
+ summary_update_needed = TRUE;
}
#ifndef G_OS_WIN32
if (all || gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(page->simplify_subject_rec_checkbtn))) {
+ gboolean old_simplify_subject = prefs->enable_simplify_subject;
+ int regexp_diffs = strcmp2(prefs->simplify_subject_regexp, gtk_editable_get_chars(
+ GTK_EDITABLE(page->entry_simplify_subject), 0, -1));
prefs->enable_simplify_subject =
gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(page->checkbtn_simplify_subject));
ASSIGN_STRING(prefs->simplify_subject_regexp,
gtk_editable_get_chars(GTK_EDITABLE(page->entry_simplify_subject), 0, -1));
+ if (old_simplify_subject != prefs->enable_simplify_subject || regexp_diffs != 0)
+ summary_update_needed = TRUE;
}
#endif
if (all || gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(page->folder_chmod_rec_checkbtn))) {
@@ -694,6 +701,11 @@
}
folder_item_prefs_save_config(folder);
+
+ if (folder->opened && summary_update_needed) {
+ summary_set_prefs_from_folderitem(folderview->summaryview, folder);
+ summary_show(folderview->summaryview, folder);
+ }
}
static gboolean general_save_recurse_func(GNode *node, gpointer data)
More information about the Commits
mailing list