rollback to 3428, before the mysterious removal of libs/* at 3431/3432
[ardour.git] / libs / libgnomecanvasmm / libgnomecanvasmm / bpath.cc
1 // Generated by gtkmmproc -- DO NOT MODIFY!
2
3 #include <libgnomecanvasmm/bpath.h>
4 #include <libgnomecanvasmm/private/bpath_p.h>
5
6 /* bpath.cc
7  *
8  * Copyright (C) 2002 The libgnomecanvasmm Development Team
9  *
10  * This library is free software; you can redistribute it and/or
11  * modify it under the terms of the GNU Library General Public
12  * License as published by the Free Software Foundation; either
13  * version 2 of the License, or (at your option) any later version.
14  *
15  * This library is distributed in the hope that it will be useful,
16  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
18  * Library General Public License for more details.
19  *
20  * You should have received a copy of the GNU Library General Public
21  * License along with this library; if not, write to the Free
22  * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
23  */
24
25 namespace Gnome
26 {
27
28 namespace Canvas
29 {
30
31
32 Bpath::Bpath(Group& parent)
33   : Shape(GNOME_CANVAS_SHAPE(g_object_new(get_type(),0)))
34 {
35   item_construct(parent);
36 }
37
38
39 void Bpath::set_bpath(const Glib::RefPtr<PathDef>& path)
40 {
41   property_bpath ().set_value ((gpointer)path->gobj());
42 }
43
44
45 } /* namespace Canvas */
46
47 } /* namespace Gnome */
48
49
50 namespace
51 {
52 } // anonymous namespace
53
54
55 namespace Glib
56 {
57
58 Gnome::Canvas::Bpath* wrap(GnomeCanvasBpath* object, bool take_copy)
59 {
60   return dynamic_cast<Gnome::Canvas::Bpath *> (Glib::wrap_auto ((GObject*)(object), take_copy));
61 }
62
63 } /* namespace Glib */
64
65 namespace Gnome
66 {
67
68 namespace Canvas
69 {
70
71
72 /* The *_Class implementation: */
73
74 const Glib::Class& Bpath_Class::init()
75 {
76   if(!gtype_) // create the GType if necessary
77   {
78     // Glib::Class has to know the class init function to clone custom types.
79     class_init_func_ = &Bpath_Class::class_init_function;
80
81     // This is actually just optimized away, apparently with no harm.
82     // Make sure that the parent type has been created.
83     //CppClassParent::CppObjectType::get_type();
84
85     // Create the wrapper type, with the same class/instance size as the base type.
86     register_derived_type(gnome_canvas_bpath_get_type());
87
88     // Add derived versions of interfaces, if the C type implements any interfaces:
89   }
90
91   return *this;
92 }
93
94 void Bpath_Class::class_init_function(void* g_class, void* class_data)
95 {
96   BaseClassType *const klass = static_cast<BaseClassType*>(g_class);
97   CppClassParent::class_init_function(klass, class_data);
98
99 }
100
101
102 Glib::ObjectBase* Bpath_Class::wrap_new(GObject* o)
103 {
104   return manage(new Bpath((GnomeCanvasBpath*)(o)));
105
106 }
107
108
109 /* The implementation: */
110
111 Bpath::Bpath(const Glib::ConstructParams& construct_params)
112 :
113   Shape(construct_params)
114 {
115   }
116
117 Bpath::Bpath(GnomeCanvasBpath* castitem)
118 :
119   Shape((GnomeCanvasShape*)(castitem))
120 {
121   }
122
123 Bpath::~Bpath()
124 {
125   destroy_();
126 }
127
128 Bpath::CppClassType Bpath::bpath_class_; // initialize static member
129
130 GType Bpath::get_type()
131 {
132   return bpath_class_.init().get_type();
133 }
134
135 GType Bpath::get_base_type()
136 {
137   return gnome_canvas_bpath_get_type();
138 }
139
140
141 Glib::PropertyProxy<gpointer> Bpath::property_bpath() 
142 {
143   return Glib::PropertyProxy<gpointer>(this, "bpath");
144 }
145
146 Glib::PropertyProxy_ReadOnly<gpointer> Bpath::property_bpath() const
147 {
148   return Glib::PropertyProxy_ReadOnly<gpointer>(this, "bpath");
149 }
150
151
152 } // namespace Canvas
153
154 } // namespace Gnome
155
156