diff options
author | Dan Winship <danw@src.gnome.org> | 2003-01-17 03:38:44 +0800 |
---|---|---|
committer | Dan Winship <danw@src.gnome.org> | 2003-01-17 03:38:44 +0800 |
commit | 2596671b8712915820d2590c86a429257ee2d8f7 (patch) | |
tree | 0fdcbb0484eca5ad23f4d52c00dcf1a445e362e1 /e-util/e-list.c | |
parent | 96b653ff426ddf7c683db4f15a7cee062a2f33c7 (diff) | |
download | gsoc2013-evolution-2596671b8712915820d2590c86a429257ee2d8f7.tar gsoc2013-evolution-2596671b8712915820d2590c86a429257ee2d8f7.tar.gz gsoc2013-evolution-2596671b8712915820d2590c86a429257ee2d8f7.tar.bz2 gsoc2013-evolution-2596671b8712915820d2590c86a429257ee2d8f7.tar.lz gsoc2013-evolution-2596671b8712915820d2590c86a429257ee2d8f7.tar.xz gsoc2013-evolution-2596671b8712915820d2590c86a429257ee2d8f7.tar.zst gsoc2013-evolution-2596671b8712915820d2590c86a429257ee2d8f7.zip |
New class, based on MailConfigAccount, for describing an evolution (mail)
* e-account.c: New class, based on MailConfigAccount, for
describing an evolution (mail) account.
* e-account-list.c: New class for tracking the list of configured
accounts. (Also uses some code from mail-config.)
* e-list.c (e_list_construct, e_list_remove): New
svn path=/trunk/; revision=19495
Diffstat (limited to 'e-util/e-list.c')
-rw-r--r-- | e-util/e-list.c | 23 |
1 files changed, 19 insertions, 4 deletions
diff --git a/e-util/e-list.c b/e-util/e-list.c index 7ef7ce2351..f1b190b16a 100644 --- a/e-util/e-list.c +++ b/e-util/e-list.c @@ -74,17 +74,23 @@ e_list_init (EList *list) } EList * -e_list_new (EListCopyFunc copy, EListFreeFunc free, void *closure) +e_list_new (EListCopyFunc copy, EListFreeFunc free, void *closure) { EList *list = g_object_new (E_TYPE_LIST, NULL); + e_list_construct (list, copy, free, closure); + return list; +} + +void +e_list_construct (EList *list, EListCopyFunc copy, EListFreeFunc free, void *closure) +{ list->copy = copy; list->free = free; list->closure = closure; - return list; } EList * -e_list_duplicate (EList *old) +e_list_duplicate (EList *old) { EList *list = g_object_new (E_TYPE_LIST, NULL); @@ -116,7 +122,7 @@ e_list_length (EList *list) } void -e_list_append (EList *list, const void *data) +e_list_append (EList *list, const void *data) { e_list_invalidate_iterators(list, NULL); if (list->copy) @@ -126,6 +132,15 @@ e_list_append (EList *list, const void *data) } void +e_list_remove (EList *list, const void *data) +{ + GList *link; + link = g_list_find (list->list, data); + if (link) + e_list_remove_link(list, link); +} + +void e_list_invalidate_iterators (EList *list, EIterator *skip) { GList *iterators = list->iterators; |