aboutsummaryrefslogtreecommitdiffstats
path: root/filter/e-filter-int.c
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2010-10-07 11:38:52 +0800
committerMatthew Barnes <mbarnes@redhat.com>2010-10-13 01:58:59 +0800
commita06e4484b8df804124b5bcf88d94dec5acfba270 (patch)
tree4fa42793d7dc461f2b3767296d76592182c48222 /filter/e-filter-int.c
parent5e0758bb6934a7859b1d8a247c8fb21c156772cf (diff)
downloadgsoc2013-evolution-a06e4484b8df804124b5bcf88d94dec5acfba270.tar.gz
gsoc2013-evolution-a06e4484b8df804124b5bcf88d94dec5acfba270.tar.zst
gsoc2013-evolution-a06e4484b8df804124b5bcf88d94dec5acfba270.zip
Give MailSession a permanent home.
Global variables in shared libraries are a bad idea. EMailBackend now owns the MailSession instance, which is actually now EMailSession. Move the blocking utility functions in mail-tools.c to e-mail-session.c and add asynchronous variants. Same approach as Camel. Replace EMailReader.get_shell_backend() with EMailReader.get_backend(), which returns an EMailBackend. Easier access to the EMailSession.
Diffstat (limited to 'filter/e-filter-int.c')
-rw-r--r--filter/e-filter-int.c17
1 files changed, 5 insertions, 12 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