1 | /* |
2 | * Copyright (c) 2008-2009 Christian Hammond |
3 | * Copyright (c) 2008-2009 David Trowbridge |
4 | * |
5 | * Permission is hereby granted, free of charge, to any person obtaining a |
6 | * copy of this software and associated documentation files (the "Software"), |
7 | * to deal in the Software without restriction, including without limitation |
8 | * the rights to use, copy, modify, merge, publish, distribute, sublicense, |
9 | * and/or sell copies of the Software, and to permit persons to whom the |
10 | * Software is furnished to do so, subject to the following conditions: |
11 | * |
12 | * The above copyright notice and this permission notice shall be included |
13 | * in all copies or substantial portions of the Software. |
14 | * |
15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR |
16 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, |
17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE |
18 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER |
19 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, |
20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN |
21 | * THE SOFTWARE. |
22 | */ |
23 | #ifndef _GTK_INSPECTOR_OBJECT_TREE_H_ |
24 | #define _GTK_INSPECTOR_OBJECT_TREE_H_ |
25 | |
26 | #include <gtk/gtkbox.h> |
27 | #include <gtk/gtktreemodel.h> |
28 | |
29 | #define GTK_TYPE_INSPECTOR_OBJECT_TREE (gtk_inspector_object_tree_get_type()) |
30 | #define GTK_INSPECTOR_OBJECT_TREE(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), GTK_TYPE_INSPECTOR_OBJECT_TREE, GtkInspectorObjectTree)) |
31 | #define GTK_INSPECTOR_OBJECT_TREE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), GTK_TYPE_INSPECTOR_OBJECT_TREE, GtkInspectorObjectTreeClass)) |
32 | #define GTK_INSPECTOR_IS_OBJECT_TREE(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj), GTK_TYPE_INSPECTOR_OBJECT_TREE)) |
33 | #define GTK_INSPECTOR_IS_OBJECT_TREE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), GTK_TYPE_INSPECTOR_OBJECT_TREE)) |
34 | #define GTK_INSPECTOR_OBJECT_TREE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS((obj), GTK_TYPE_INSPECTOR_OBJECT_TREE, GtkInspectorObjectTreeClass)) |
35 | |
36 | |
37 | typedef struct _GtkInspectorObjectTreePrivate GtkInspectorObjectTreePrivate; |
38 | |
39 | typedef struct _GtkInspectorObjectTree |
40 | { |
41 | GtkBox parent; |
42 | GtkInspectorObjectTreePrivate *priv; |
43 | } GtkInspectorObjectTree; |
44 | |
45 | typedef struct _GtkInspectorObjectTreeClass |
46 | { |
47 | GtkBoxClass parent; |
48 | |
49 | void (*object_selected) (GtkInspectorObjectTree *wt, |
50 | GObject *object); |
51 | void (*object_activated) (GtkInspectorObjectTree *wt, |
52 | GObject *object); |
53 | } GtkInspectorObjectTreeClass; |
54 | |
55 | |
56 | G_BEGIN_DECLS |
57 | |
58 | |
59 | GType gtk_inspector_object_tree_get_type (void); |
60 | |
61 | char * gtk_inspector_get_object_title (GObject *object); |
62 | |
63 | void gtk_inspector_object_tree_select_object (GtkInspectorObjectTree *wt, |
64 | GObject *object); |
65 | void gtk_inspector_object_tree_activate_object (GtkInspectorObjectTree *wt, |
66 | GObject *object); |
67 | |
68 | GObject *gtk_inspector_object_tree_get_selected (GtkInspectorObjectTree *wt); |
69 | |
70 | void gtk_inspector_object_tree_set_display (GtkInspectorObjectTree *wt, |
71 | GdkDisplay *display); |
72 | |
73 | G_END_DECLS |
74 | |
75 | |
76 | #endif // _GTK_INSPECTOR_WIDGETTREE_H_ |
77 | |
78 | // vim: set et sw=2 ts=2: |
79 | |