aboutsummaryrefslogtreecommitdiffstats
path: root/e-util/e-util.c
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@src.gnome.org>2009-03-21 03:06:59 +0800
committerMatthew Barnes <mbarnes@src.gnome.org>2009-03-21 03:06:59 +0800
commit4cec9fc7169dc3b810321555a70cda916720867d (patch)
tree8fe739ab0d249fb35bedc572bd34b3717512283b /e-util/e-util.c
parent7a92d9cc82b7775a0f5cb1fde233119d435a79b6 (diff)
downloadgsoc2013-evolution-4cec9fc7169dc3b810321555a70cda916720867d.tar.gz
gsoc2013-evolution-4cec9fc7169dc3b810321555a70cda916720867d.tar.zst
gsoc2013-evolution-4cec9fc7169dc3b810321555a70cda916720867d.zip
Saving progress on a massive attachment handling rewrite.
svn path=/branches/kill-bonobo/; revision=37465
Diffstat (limited to 'e-util/e-util.c')
-rw-r--r--e-util/e-util.c37
1 files changed, 23 insertions, 14 deletions
diff --git a/e-util/e-util.c b/e-util/e-util.c
index e4e9a3ac32..02c76c3d32 100644
--- a/e-util/e-util.c
+++ b/e-util/e-util.c
@@ -1529,23 +1529,32 @@ e_util_read_file (const char *filename, gboolean filename_is_uri, char **buffer,
return res;
}
-GSList *
-e_util_get_category_filter_options (void)
+static gpointer
+e_camel_object_copy (gpointer camel_object)
{
- GSList *res = NULL;
- GList *clist, *l;
+ if (CAMEL_IS_OBJECT (camel_object))
+ camel_object_ref (camel_object);
- clist = e_categories_get_list ();
- for (l = clist; l; l = l->next) {
- const char *cname = l->data;
- struct _filter_option *fo = g_new0 (struct _filter_option, 1);
+ return camel_object;
+}
- fo->title = g_strdup (cname);
- fo->value = g_strdup (cname);
- res = g_slist_prepend (res, fo);
- }
+static void
+e_camel_object_free (gpointer camel_object)
+{
+ if (CAMEL_IS_OBJECT (camel_object))
+ camel_object_unref (camel_object);
+}
+
+GType
+e_camel_object_get_type (void)
+{
+ static GType type = 0;
- g_list_free (clist);
+ if (G_UNLIKELY (type == 0))
+ type = g_boxed_type_register_static (
+ "ECamelObject",
+ (GBoxedCopyFunc) e_camel_object_copy,
+ (GBoxedFreeFunc) e_camel_object_free);
- return g_slist_reverse (res);
+ return type;
}