GnuCash  2.6.99
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
gnc-sx-list-tree-model-adapter.h
1 /*
2  * gnc-sx-list-tree-model-adapter.h
3  *
4  * Copyright (C) 2006 Josh Sled <[email protected]>
5  *
6  * This program is free software; you can redistribute it and/or
7  * modify it under the terms of version 2 and/or version 3 of the GNU General Public
8  * License as published by the Free Software Foundation.
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  * GNU General Public License for more details.
14  *
15  * You should have received a copy of the GNU General Public License
16  * along with this program; if not, contact:
17  *
18  * Free Software Foundation Voice: +1-617-542-5942
19  * 51 Franklin Street, Fifth Floor Fax: +1-617-542-2652
20  * Boston, MA 02110-1301, USA [email protected]
21  */
22 
23 #ifndef _GNC_SX_LIST_TREE_MODEL_ADAPTER_H
24 #define _GNC_SX_LIST_TREE_MODEL_ADAPTER_H
25 
26 #include "config.h"
27 #include <glib.h>
28 #include <glib-object.h>
29 #include <gtk/gtk.h>
30 #include "gnc-sx-instance-model.h"
31 
32 G_BEGIN_DECLS
33 
34 #define GNC_TYPE_SX_LIST_TREE_MODEL_ADAPTER (gnc_sx_list_tree_model_adapter_get_type ())
35 #define GNC_SX_LIST_TREE_MODEL_ADAPTER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GNC_TYPE_SX_LIST_TREE_MODEL_ADAPTER, GncSxListTreeModelAdapter))
36 #define GNC_SX_LIST_TREE_MODEL_ADAPTER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GNC_TYPE_SX_LIST_TREE_MODEL_ADAPTER, GncSxListTreeModelAdapterClass))
37 #define GNC_IS_SX_LIST_TREE_MODEL_ADAPTER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GNC_TYPE_SX_LIST_TREE_MODEL_ADAPTER))
38 #define GNC_IS_SX_LIST_TREE_MODEL_ADAPTER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GNC_TYPE_SX_LIST_TREE_MODEL_ADAPTER))
39 #define GNC_SX_LIST_TREE_MODEL_ADAPTER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GNC_TYPE_SX_LIST_TREE_MODEL_ADAPTER, GncSxListTreeModelAdapterClass))
40 
43 
44 // model columns
45 enum
46 {
47  SXLTMA_COL_NAME = 0,
48  SXLTMA_COL_ENABLED,
49  SXLTMA_COL_FREQUENCY,
50  SXLTMA_COL_LAST_OCCUR,
51  SXLTMA_COL_NEXT_OCCUR
52 };
53 
54 GType gnc_sx_list_tree_model_adapter_get_type(void);
55 GncSxListTreeModelAdapter* gnc_sx_list_tree_model_adapter_new(GncSxInstanceModel *instances);
56 
57 GncSxInstances* gnc_sx_list_tree_model_adapter_get_sx_instances(GncSxListTreeModelAdapter *model, GtkTreeIter *iter);
58 
59 G_END_DECLS
60 
61 #endif // _GNC_SX_LIST_TREE_MODEL_ADAPTER_H