diff options
author | Not Zed <NotZed@HelixCode.com> | 2000-10-09 20:48:38 +0800 |
---|---|---|
committer | Michael Zucci <zucchi@src.gnome.org> | 2000-10-09 20:48:38 +0800 |
commit | d0d1c0e3d92f083304a152f633c4448b1975181a (patch) | |
tree | e373128ed58cd529b8660eb2e5cc817d778ac4f2 /filter/rule-context.c | |
parent | f3159dd29e59cbaec931e2985384cda805471925 (diff) | |
download | gsoc2013-evolution-d0d1c0e3d92f083304a152f633c4448b1975181a.tar.gz gsoc2013-evolution-d0d1c0e3d92f083304a152f633c4448b1975181a.tar.zst gsoc2013-evolution-d0d1c0e3d92f083304a152f633c4448b1975181a.zip |
Remove the stupid on-demand cb shit. (rule_context_load): And here too.
2000-10-06 Not Zed <NotZed@HelixCode.com>
* rule-context.c (load): Remove the stupid on-demand cb shit.
(rule_context_load): And here too.
svn path=/trunk/; revision=5797
Diffstat (limited to 'filter/rule-context.c')
-rw-r--r-- | filter/rule-context.c | 23 |
1 files changed, 6 insertions, 17 deletions
diff --git a/filter/rule-context.c b/filter/rule-context.c index 743e2507c9..be3c2e5540 100644 --- a/filter/rule-context.c +++ b/filter/rule-context.c @@ -26,8 +26,7 @@ #define d(x) -static int load(RuleContext *f, const char *system, const char *user, - RCRegisterFunc on_demand_cb, gpointer user_data); +static int load(RuleContext *f, const char *system, const char *user); static int save(RuleContext *f, const char *user); static void rule_context_class_init (RuleContextClass *class); @@ -168,25 +167,19 @@ rule_context_set_error(RuleContext *f, char *error) * @f: * @system: * @user: - * @on_demand_cb: An optional callback to allow UI registration of on-demand rules - * @user_data: Extra data for the callback - * + * * Load a rule context from a system and user description file. * * Return value: **/ -int rule_context_load(RuleContext *f, const char *system, const char *user, - RCRegisterFunc on_demand_cb, gpointer user_data ) +int rule_context_load(RuleContext *f, const char *system, const char *user) { d(printf("rule_context: loading %s %s\n", system, user)); - return ((RuleContextClass *)((GtkObject *)f)->klass)->load(f, system, user, - on_demand_cb, - user_data); + return ((RuleContextClass *)((GtkObject *)f)->klass)->load(f, system, user); } -static int load(RuleContext *f, const char *system, const char *user, - RCRegisterFunc on_demand_cb, gpointer user_data) +static int load(RuleContext *f, const char *system, const char *user) { xmlNodePtr set, rule; struct _part_set_map *part_map; @@ -203,8 +196,7 @@ static int load(RuleContext *f, const char *system, const char *user, return -1; } if (strcmp(f->system->root->name, "filterdescription")) { - rule_context_set_error(f, g_strdup_printf("Unable to load system rules '%s': Invalid format", - system)); + rule_context_set_error(f, g_strdup_printf("Unable to load system rules '%s': Invalid format", system)); xmlFreeDoc(f->system); f->system = NULL; return -1; @@ -252,9 +244,6 @@ static int load(RuleContext *f, const char *system, const char *user, FilterRule *part = FILTER_RULE(gtk_type_new(rule_map->type)); if (filter_rule_xml_decode(part, rule, f) == 0) { rule_map->append(f, part); - - if (on_demand_cb && part->source == FILTER_SOURCE_DEMAND) - (on_demand_cb) (f, part, user_data); } else { gtk_object_unref((GtkObject *)part); g_warning("Cannot load filter part"); |