aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNot Zed <NotZed@Ximian.com>2002-08-06 13:23:13 +0800
committerMichael Zucci <zucchi@src.gnome.org>2002-08-06 13:23:13 +0800
commit1402b68e05a1f701bed2a9cb377fe02cbe69109e (patch)
tree7ca7952832fe44d50d87174becd9a19bf68b99c8
parent3f8d6fddb31765e20d66e78778c1916ea8618c36 (diff)
downloadgsoc2013-evolution-1402b68e05a1f701bed2a9cb377fe02cbe69109e.tar.gz
gsoc2013-evolution-1402b68e05a1f701bed2a9cb377fe02cbe69109e.tar.zst
gsoc2013-evolution-1402b68e05a1f701bed2a9cb377fe02cbe69109e.zip
Set the rule name to include the search string, for #10979.
2002-08-06 Not Zed <NotZed@Ximian.com> * folder-browser.c (folder_browser_search_menu_activated): Set the rule name to include the search string, for #10979. svn path=/trunk/; revision=17712
-rw-r--r--mail/ChangeLog5
-rw-r--r--mail/folder-browser.c9
2 files changed, 12 insertions, 2 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog
index d586c6451f..831ad6dc5b 100644
--- a/mail/ChangeLog
+++ b/mail/ChangeLog
@@ -1,9 +1,12 @@
2002-08-06 Not Zed <NotZed@Ximian.com>
+ * folder-browser.c (folder_browser_search_menu_activated): Set the
+ rule name to include the search string, for #10979.
+
* message-list.c (message_list_hidden): Only count hidden messages
which are in the folder. Should probably maintain hidden table
better. For #4334.
-
+
* mail-ops.c (filter_folder_filter): Unref the driver before
returning to main thread, so any closing operations are handled
async (as in fetch_mail_fetch()), for #28072.
diff --git a/mail/folder-browser.c b/mail/folder-browser.c
index b367d124d3..da11702d2c 100644
--- a/mail/folder-browser.c
+++ b/mail/folder-browser.c
@@ -1104,7 +1104,14 @@ folder_browser_search_menu_activated (ESearchBar *esb, int id, FolderBrowser *fb
d(printf("Save vfolder\n"));
if (efb->current_query) {
FilterRule *rule = vfolder_clone_rule(efb->current_query);
-
+ char *name, *text;
+
+ text = e_search_bar_get_text(esb);
+ name = g_strdup_printf("%s %s", rule->name, (text&&text[0])?text:"''");
+ g_free(text);
+ filter_rule_set_name(rule, name);
+ g_free(name);
+
filter_rule_set_source(rule, FILTER_SOURCE_INCOMING);
vfolder_rule_add_source((VfolderRule *)rule, fb->uri);
vfolder_gui_add_rule((VfolderRule *)rule);