diff options
author | Christopher James Lahey <clahey@helixcode.com> | 2000-05-31 10:58:37 +0800 |
---|---|---|
committer | Chris Lahey <clahey@src.gnome.org> | 2000-05-31 10:58:37 +0800 |
commit | 64e74a631c44364553aac9d4aff2e5cb83f3e81b (patch) | |
tree | f6712b6b54d06108108208e0724bb860fd84b1c7 /addressbook/gui/component/e-cardlist-model.h | |
parent | c4fe21d4f65bd9e8dbdf2a6c873225fb821096f6 (diff) | |
download | gsoc2013-evolution-64e74a631c44364553aac9d4aff2e5cb83f3e81b.tar.gz gsoc2013-evolution-64e74a631c44364553aac9d4aff2e5cb83f3e81b.tar.zst gsoc2013-evolution-64e74a631c44364553aac9d4aff2e5cb83f3e81b.zip |
New files for card list.
2000-05-30 Christopher James Lahey <clahey@helixcode.com>
* gui/component/e-cardlist-model.c,
gui/component/e-cardlist-model.h: New files for card list.
svn path=/trunk/; revision=3309
Diffstat (limited to 'addressbook/gui/component/e-cardlist-model.h')
-rw-r--r-- | addressbook/gui/component/e-cardlist-model.h | 49 |
1 files changed, 49 insertions, 0 deletions
diff --git a/addressbook/gui/component/e-cardlist-model.h b/addressbook/gui/component/e-cardlist-model.h new file mode 100644 index 0000000000..4a04bbf225 --- /dev/null +++ b/addressbook/gui/component/e-cardlist-model.h @@ -0,0 +1,49 @@ +/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */ +#ifndef _E_CARDLIST_MODEL_H_ +#define _E_CARDLIST_MODEL_H_ + +#include "e-table-model.h" +#include <ebook/e-book.h> +#include <ebook/e-book-view.h> +#include <ebook/e-card-simple.h> + +#define E_CARDLIST_MODEL_TYPE (e_cardlist_model_get_type ()) +#define E_CARDLIST_MODEL(o) (GTK_CHECK_CAST ((o), E_CARDLIST_MODEL_TYPE, ECardlistModel)) +#define E_CARDLIST_MODEL_CLASS(k) (GTK_CHECK_CLASS_CAST((k), E_CARDLIST_MODEL_TYPE, ECardlistModelClass)) +#define E_IS_CARDLIST_MODEL(o) (GTK_CHECK_TYPE ((o), E_CARDLIST_MODEL_TYPE)) +#define E_IS_CARDLIST_MODEL_CLASS(k) (GTK_CHECK_CLASS_TYPE ((k), E_CARDLIST_MODEL_TYPE)) + +/* Virtual Column list: + 0 Email + 1 Full Name + 2 Street + 3 Phone +*/ + +typedef struct { + ETableModel parent; + + /* item specific fields */ + ECardSimple **data; + int data_count; +} ECardlistModel; + + +typedef struct { + ETableModelClass parent_class; +} ECardlistModelClass; + + +GtkType e_cardlist_model_get_type (void); +ETableModel *e_cardlist_model_new (void); + +/* Returns object with an extra ref count. */ +ECard *e_cardlist_model_get_card(ECardlistModel *model, + int row); +void add_card (ECardlistModel *model, + ECard **card, + int count); +void remove_card (ECardlistModel *model, + const char *id); + +#endif /* _E_CARDLIST_MODEL_H_ */ |