#include "folder.h"
#include "scoring.h"
+#include "matcher_parser.h"
+
static struct Scoring {
GtkWidget *window;
while (gtk_clist_get_text(GTK_CLIST(scoring.cond_clist),
row, 0, &scoring_str)) {
if (strcmp(scoring_str, _("(New)")) != 0) {
- tmp = scoring_str;
- prop = scoringprop_parse(&tmp);
+ /* tmp = scoring_str; */
+ prop = matcher_parser_get_scoring(scoring_str);
if (prop != NULL)
prefs_scoring = g_slist_append(prefs_scoring,
prop);
if (*cond_str != '\0') {
gchar * tmp;
- tmp = cond_str;
- matchers = matcherlist_parse(&tmp);
- if (tmp == NULL)
+ /* tmp = cond_str; */
+ matchers = matcher_parser_get_cond(cond_str);
+ if (matchers == NULL)
alertpanel_error(_("Match string is not valid."));
}
}
score = atoi(score_str);
- tmp = cond_str;
- cond = matcherlist_parse(&tmp);
+ /* tmp = cond_str; */
+ cond = matcher_parser_get_cond(cond_str);
- if (tmp == NULL) {
+ if (cond == NULL) {
alertpanel_error(_("Match string is not valid."));
return;
}
}
score = atoi(score_str);
- tmp = cond_str;
- cond = matcherlist_parse(&tmp);
+ /* tmp = cond_str; */
+ cond = matcher_parser_get_cond(cond_str);
- if (tmp == NULL) {
+ if (cond == NULL) {
alertpanel_error(_("Match string is not valid."));
return;
}
row, 0, &scoring_str))
return;
- tmp = scoring_str;
- prop = scoringprop_parse(&tmp);
- if (tmp == NULL)
+ /* tmp = scoring_str; */
+ prop = matcher_parser_get_scoring(scoring_str);
+ if (prop == NULL)
return;
prefs_scoring_select_set_dialog(prop);
static void prefs_scoring_ok(void)
{
+ prefs_common_save_config();
prefs_scoring_set_list();
- prefs_scoring_write_config();
+ prefs_matcher_write_config();
if (cur_item != NULL)
prefs_folder_item_save_config(cur_item);
gtk_widget_hide(scoring.window);
static void prefs_scoring_cancel(void)
{
- prefs_scoring_read_config();
+ prefs_matcher_read_config();
gtk_widget_hide(scoring.window);
}