From 422046cc58a534f6916205f282cc6b50a98eeb95 Mon Sep 17 00:00:00 2001 From: Chris Toshok Date: Fri, 23 Jun 2000 07:47:37 +0000 Subject: add icon_at virtual function - it was stupid to make the insert call take 2000-06-23 Chris Toshok * e-tree-model.h, e-tree-model.c: add icon_at virtual function - it was stupid to make the insert call take 2 pixbufs. the model should give this information. * e-cell-tree.c: get rid of the opened/closed pixbuf stuff. call e_tree_model_icon_of_node. * e-tree-example-1.c: add my_icon_at. * e-tree-simple.c (simple_icon_at): new function (e_tree_simple_new): add icon_at parameter. * e-tree-simple.h: add SimpleIconAtFn. svn path=/trunk/; revision=3707 --- widgets/e-table/e-tree-simple.h | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'widgets/e-table/e-tree-simple.h') diff --git a/widgets/e-table/e-tree-simple.h b/widgets/e-table/e-tree-simple.h index 6820b14673..edda53e82d 100644 --- a/widgets/e-table/e-tree-simple.h +++ b/widgets/e-table/e-tree-simple.h @@ -12,13 +12,15 @@ #define E_IS_TREE_SIMPLE_CLASS(k) (GTK_CHECK_CLASS_TYPE ((k), E_TREE_SIMPLE_TYPE)) -typedef void* (*ETreeSimpleValueAtFn) (ETreeModel *etree, ETreePath *path, int col, void *model_data); -typedef void (*ETreeSimpleSetValueAtFn) (ETreeModel *etree, ETreePath *path, int col, const void *val, void *model_data); -typedef gboolean (*ETreeSimpleIsEditableFn) (ETreeModel *etree, ETreePath *path, int col, void *model_data); +typedef GdkPixbuf* (*ETreeSimpleIconAtFn) (ETreeModel *etree, ETreePath *path, void *model_data); +typedef void* (*ETreeSimpleValueAtFn) (ETreeModel *etree, ETreePath *path, int col, void *model_data); +typedef void (*ETreeSimpleSetValueAtFn) (ETreeModel *etree, ETreePath *path, int col, const void *val, void *model_data); +typedef gboolean (*ETreeSimpleIsEditableFn) (ETreeModel *etree, ETreePath *path, int col, void *model_data); typedef struct { ETreeModel parent; + ETreeSimpleIconAtFn icon_at; ETreeSimpleValueAtFn value_at; ETreeSimpleSetValueAtFn set_value_at; ETreeSimpleIsEditableFn is_editable; @@ -32,7 +34,8 @@ typedef struct { GtkType e_tree_simple_get_type (void); -ETreeModel *e_tree_simple_new (ETreeSimpleValueAtFn value_at, +ETreeModel *e_tree_simple_new (ETreeSimpleIconAtFn icon_at, + ETreeSimpleValueAtFn value_at, ETreeSimpleSetValueAtFn set_value_at, ETreeSimpleIsEditableFn is_editable, gpointer model_data); -- cgit