1 // Generated by gmmproc 2.60.0 -- DO NOT MODIFY!
2 
3 #undef GTK_DISABLE_DEPRECATED
4 #define GDK_DISABLE_DEPRECATION_WARNINGS 1
5 
6 
7 #ifndef GTKMM_DISABLE_DEPRECATED
8 
9 
10 #include <glibmm.h>
11 
12 #include <gtkmm/iconfactory.h>
13 #include <gtkmm/private/iconfactory_p.h>
14 
15 
16 /*
17  * Copyright 1998-2002 The gtkmm Development Team
18  *
19  * This library is free software; you can redistribute it and/or
20  * modify it under the terms of the GNU Lesser General Public
21  * License as published by the Free Software Foundation; either
22  * version 2.1 of the License, or (at your option) any later version.
23  *
24  * This library is distributed in the hope that it will be useful,
25  * but WITHOUT ANY WARRANTY; without even the implied warranty of
26  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
27  * Lesser General Public License for more details.
28  *
29  * You should have received a copy of the GNU Lesser General Public
30  * License along with this library; if not, write to the Free Software
31  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
32  */
33 
34 #include <gtk/gtk.h>
35 
36 
37 namespace
38 {
39 } // anonymous namespace
40 
41 
42 namespace Glib
43 {
44 
wrap(GtkIconFactory * object,bool take_copy)45 Glib::RefPtr<Gtk::IconFactory> wrap(GtkIconFactory* object, bool take_copy)
46 {
47   return Glib::RefPtr<Gtk::IconFactory>( dynamic_cast<Gtk::IconFactory*> (Glib::wrap_auto ((GObject*)(object), take_copy)) );
48   //We use dynamic_cast<> in case of multiple inheritance.
49 }
50 
51 } /* namespace Glib */
52 
53 
54 namespace Gtk
55 {
56 
57 
58 /* The *_Class implementation: */
59 
init()60 const Glib::Class& IconFactory_Class::init()
61 {
62   if(!gtype_) // create the GType if necessary
63   {
64     // Glib::Class has to know the class init function to clone custom types.
65     class_init_func_ = &IconFactory_Class::class_init_function;
66 
67     // This is actually just optimized away, apparently with no harm.
68     // Make sure that the parent type has been created.
69     //CppClassParent::CppObjectType::get_type();
70 
71     // Create the wrapper type, with the same class/instance size as the base type.
72     register_derived_type(gtk_icon_factory_get_type());
73 
74     // Add derived versions of interfaces, if the C type implements any interfaces:
75 
76   }
77 
78   return *this;
79 }
80 
81 
class_init_function(void * g_class,void * class_data)82 void IconFactory_Class::class_init_function(void* g_class, void* class_data)
83 {
84   const auto klass = static_cast<BaseClassType*>(g_class);
85   CppClassParent::class_init_function(klass, class_data);
86 
87 
88 }
89 
90 
wrap_new(GObject * object)91 Glib::ObjectBase* IconFactory_Class::wrap_new(GObject* object)
92 {
93   return new IconFactory((GtkIconFactory*)object);
94 }
95 
96 
97 /* The implementation: */
98 
gobj_copy()99 GtkIconFactory* IconFactory::gobj_copy()
100 {
101   reference();
102   return gobj();
103 }
104 
IconFactory(const Glib::ConstructParams & construct_params)105 IconFactory::IconFactory(const Glib::ConstructParams& construct_params)
106 :
107   Glib::Object(construct_params)
108 {
109 
110 }
111 
IconFactory(GtkIconFactory * castitem)112 IconFactory::IconFactory(GtkIconFactory* castitem)
113 :
114   Glib::Object((GObject*)(castitem))
115 {}
116 
117 
IconFactory(IconFactory && src)118 IconFactory::IconFactory(IconFactory&& src) noexcept
119 : Glib::Object(std::move(src))
120 {}
121 
operator =(IconFactory && src)122 IconFactory& IconFactory::operator=(IconFactory&& src) noexcept
123 {
124   Glib::Object::operator=(std::move(src));
125   return *this;
126 }
127 
128 
~IconFactory()129 IconFactory::~IconFactory() noexcept
130 {}
131 
132 
133 IconFactory::CppClassType IconFactory::iconfactory_class_; // initialize static member
134 
get_type()135 GType IconFactory::get_type()
136 {
137   return iconfactory_class_.init().get_type();
138 }
139 
140 
get_base_type()141 GType IconFactory::get_base_type()
142 {
143   return gtk_icon_factory_get_type();
144 }
145 
146 
IconFactory()147 IconFactory::IconFactory()
148 :
149   // Mark this class as non-derived to allow C++ vfuncs to be skipped.
150   Glib::ObjectBase(nullptr),
151   Glib::Object(Glib::ConstructParams(iconfactory_class_.init()))
152 {
153 
154 
155 }
156 
create()157 Glib::RefPtr<IconFactory> IconFactory::create()
158 {
159   return Glib::RefPtr<IconFactory>( new IconFactory() );
160 }
161 
add(const Gtk::StockID & stock_id,const Glib::RefPtr<IconSet> & icon_set)162 void IconFactory::add(const Gtk::StockID& stock_id, const Glib::RefPtr<IconSet>& icon_set)
163 {
164   gtk_icon_factory_add(gobj(), (stock_id).get_c_str(), Glib::unwrap(icon_set));
165 }
166 
add_default()167 void IconFactory::add_default()
168 {
169   gtk_icon_factory_add_default(gobj());
170 }
171 
remove_default()172 void IconFactory::remove_default()
173 {
174   gtk_icon_factory_remove_default(gobj());
175 }
176 
177 
178 } // namespace Gtk
179 
180 #endif // GTKMM_DISABLE_DEPRECATED
181 
182 
183