aboutsummaryrefslogtreecommitdiffstats
path: root/filter/rule-context.c
diff options
context:
space:
mode:
Diffstat (limited to 'filter/rule-context.c')
-rw-r--r--filter/rule-context.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/filter/rule-context.c b/filter/rule-context.c
index 07a3775e3e..61fa4cbf1b 100644
--- a/filter/rule-context.c
+++ b/filter/rule-context.c
@@ -35,6 +35,7 @@
#include <gtk/gtk.h>
#include <libgnome/gnome-i18n.h>
#include <gal/util/e-xml-utils.h>
+#include "widgets/misc/e-error.h"
#include "rule-context.h"
#include "filter-rule.h"
@@ -677,14 +678,7 @@ new_rule_response(GtkWidget *dialog, int button, RuleContext *context)
}
if (rule_context_find_rule (context, rule->name, rule->source)) {
- dialog = gtk_message_dialog_new ((GtkWindow *) dialog, GTK_DIALOG_DESTROY_WITH_PARENT,
- GTK_MESSAGE_ERROR, GTK_BUTTONS_CLOSE,
- _("Rule name '%s' is not unique, choose another."),
- rule->name);
-
- gtk_dialog_set_has_separator ((GtkDialog *) dialog, FALSE);
- gtk_dialog_run ((GtkDialog *) dialog);
- gtk_widget_destroy (dialog);
+ e_error_run((GtkWindow *)dialog, "filter:bad-name-notunique", rule->name, NULL);
return;
}