From 29a313c41efa7844952000a88d772af11fbb6f37 Mon Sep 17 00:00:00 2001 From: Chris Toshok Date: Fri, 23 Jun 2000 07:19:11 +0000 Subject: use the expanded/unexpanded pixbufs as node pixbufs for the first level of 2000-06-23 Chris Toshok * e-tree-example-1.c (create_tree): use the expanded/unexpanded pixbufs as node pixbufs for the first level of children, to test the drawing. * e-tree-model.c (e_tree_model_node_get_closed_pixbuf): new function. (e_tree_model_node_get_opened_pixbuf): same. (e_tree_model_node_insert): add opened/closed pixbuf argument. (e_tree_model_node_insert_before): same. * e-tree-model.h: add prototypes for opened/closed pixbuf accessors, and add them to the e_tree_model_node_insert_* calls. * e-cell-tree.c (ect_draw): add opened/closed pixbuf drawing per node. svn path=/trunk/; revision=3706 --- widgets/table/e-tree-model.h | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'widgets/table/e-tree-model.h') diff --git a/widgets/table/e-tree-model.h b/widgets/table/e-tree-model.h index 45351b8f6c..0a7ecdb7ed 100644 --- a/widgets/table/e-tree-model.h +++ b/widgets/table/e-tree-model.h @@ -3,6 +3,7 @@ #define _E_TREE_MODEL_H_ #include "e-table-model.h" +#include "gdk-pixbuf/gdk-pixbuf.h" #define E_TREE_MODEL_TYPE (e_tree_model_get_type ()) #define E_TREE_MODEL(o) (GTK_CHECK_CAST ((o), E_TREE_MODEL_TYPE, ETreeModel)) @@ -68,8 +69,8 @@ ETreePath *e_tree_model_node_get_next (ETreeModel *etree, ETreePath *path); ETreePath *e_tree_model_node_get_prev (ETreeModel *etree, ETreePath *path); /* node operations */ -ETreePath *e_tree_model_node_insert (ETreeModel *etree, ETreePath *parent, int position, gpointer node_data); -ETreePath *e_tree_model_node_insert_before (ETreeModel *etree, ETreePath *parent, ETreePath *sibling, gpointer node_data); +ETreePath *e_tree_model_node_insert (ETreeModel *etree, ETreePath *parent, int position, GdkPixbuf *opened_pixbuf, GdkPixbuf *closed_pixbuf, gpointer node_data); +ETreePath *e_tree_model_node_insert_before (ETreeModel *etree, ETreePath *parent, ETreePath *sibling, GdkPixbuf *opened_pixbuf, GdkPixbuf *closed_pixbuf, gpointer node_data); gpointer e_tree_model_node_remove (ETreeModel *etree, ETreePath *path); /* node accessors */ @@ -84,6 +85,8 @@ guint e_tree_model_node_depth (ETreeModel *etree, ETreePath guint e_tree_model_node_num_visible_descendents (ETreeModel *etm, ETreePath *node); gpointer e_tree_model_node_get_data (ETreeModel *etm, ETreePath *node); void e_tree_model_node_set_data (ETreeModel *etm, ETreePath *node, gpointer node_data); +GdkPixbuf *e_tree_model_node_get_opened_pixbuf (ETreeModel *etm, ETreePath *node); +GdkPixbuf *e_tree_model_node_get_closed_pixbuf (ETreeModel *etm, ETreePath *node); /* display oriented routines */ ETreePath *e_tree_model_node_at_row (ETreeModel *etree, int row); -- cgit