diff options
Diffstat (limited to 'filter')
-rw-r--r-- | filter/e-filter-int.c | 17 | ||||
-rw-r--r-- | filter/e-filter-int.h | 4 | ||||
-rw-r--r-- | filter/e-filter-option.c | 9 | ||||
-rw-r--r-- | filter/e-filter-option.h | 2 |
4 files changed, 9 insertions, 23 deletions
diff --git a/filter/e-filter-int.c b/filter/e-filter-int.c index 871e595505..3fcfe872e3 100644 --- a/filter/e-filter-int.c +++ b/filter/e-filter-int.c @@ -77,7 +77,7 @@ filter_int_clone (EFilterElement *element) EFilterInt *filter_int = E_FILTER_INT (element); EFilterInt *clone; - clone = e_filter_int_new_type ( + clone = (EFilterInt *) e_filter_int_new_type ( filter_int->type, filter_int->min, filter_int->max); clone->val = filter_int->val; @@ -200,33 +200,26 @@ e_filter_int_init (EFilterInt *filter_int) filter_int->max = G_MAXINT; } -/** - * filter_int_new: - * - * Create a new EFilterInt object. - * - * Return value: A new #EFilterInt object. - **/ -EFilterInt * +EFilterElement * e_filter_int_new (void) { return g_object_new (E_TYPE_FILTER_INT, NULL); } -EFilterInt * +EFilterElement * e_filter_int_new_type (const gchar *type, gint min, gint max) { EFilterInt *filter_int; - filter_int = e_filter_int_new (); + filter_int = g_object_new (E_TYPE_FILTER_INT, NULL); filter_int->type = g_strdup (type); filter_int->min = min; filter_int->max = max; - return filter_int; + return E_FILTER_ELEMENT (filter_int); } void diff --git a/filter/e-filter-int.h b/filter/e-filter-int.h index c9f613c9a3..be0aa4e65a 100644 --- a/filter/e-filter-int.h +++ b/filter/e-filter-int.h @@ -65,8 +65,8 @@ struct _EFilterIntClass { }; GType e_filter_int_get_type (void); -EFilterInt * e_filter_int_new (void); -EFilterInt * e_filter_int_new_type (const gchar *type, +EFilterElement *e_filter_int_new (void); +EFilterElement *e_filter_int_new_type (const gchar *type, gint min, gint max); void e_filter_int_set_value (EFilterInt *f_int, diff --git a/filter/e-filter-option.c b/filter/e-filter-option.c index c0ce5b778f..e8a4dcc4ae 100644 --- a/filter/e-filter-option.c +++ b/filter/e-filter-option.c @@ -425,14 +425,7 @@ e_filter_option_init (EFilterOption *option) option->dynamic_func = NULL; } -/** - * filter_option_new: - * - * Create a new EFilterOption object. - * - * Return value: A new #EFilterOption object. - **/ -EFilterOption * +EFilterElement * e_filter_option_new (void) { return g_object_new (E_TYPE_FILTER_OPTION, NULL); diff --git a/filter/e-filter-option.h b/filter/e-filter-option.h index c42efe2fe3..45d426b761 100644 --- a/filter/e-filter-option.h +++ b/filter/e-filter-option.h @@ -75,7 +75,7 @@ struct _EFilterOptionClass { }; GType e_filter_option_get_type (void); -EFilterOption * e_filter_option_new (void); +EFilterElement *e_filter_option_new (void); void e_filter_option_set_current (EFilterOption *option, const gchar *name); const gchar * e_filter_option_get_current (EFilterOption *option); |