talons

Fork of Claws Mail https://www.claws-mail
Log | Files | Refs | README | LICENSE

commit 9278a0825e350d0bb2502c6f8760be3f47565993
parent f8cbcff32aa9014d9924c30d5d3604dac070b661
Author: wwp <subscript@free.fr>
Date:   Thu, 20 Sep 2018 22:16:33 +0200

Quicksearch: expand extended symbols on "Edit", patch by Olivier Brunel.

Diffstat:
Msrc/gtk/quicksearch.c | 10+++++++---
1 file changed, 7 insertions(+), 3 deletions(-)

diff --git a/src/gtk/quicksearch.c b/src/gtk/quicksearch.c @@ -594,12 +594,16 @@ static gboolean search_condition_expr(GtkMenuItem *widget, gpointer data) mainwindow_get_mainwindow()->summaryview->quicksearch != NULL, FALSE); - /* re-use the current quicksearch value if it's a condition expression, - otherwise ignore it silently */ + /* re-use the current quicksearch value, expanding it so it also works + * with extended symbols */ cond_str = quicksearch_get_text(mainwindow_get_mainwindow()->summaryview->quicksearch); if (*cond_str != '\0') { - matchers = matcher_parser_get_cond((gchar*)cond_str, NULL); + gchar *newstr = advsearch_expand_search_string(cond_str); + + if (newstr && newstr[0] != '\0') + matchers = matcher_parser_get_cond(newstr, FALSE); + g_free(newstr); } prefs_matcher_open(matchers, search_condition_expr_done);