Update contrib.
2 * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). All rights reserved.
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the
16 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
17 * Boston, MA 02111-1307, USA.
25 extern GType baz_type;
28 maman_ibaz_base_init (gpointer g_class)
34 maman_ibaz_get_type (void)
36 static GType type = 0;
38 static const GTypeInfo info = {
39 sizeof (MamanIbazInterface),
40 maman_ibaz_base_init, /* base_init */
41 NULL, /* base_finalize */
42 NULL, /* class_init */
43 NULL, /* class_finalize */
44 NULL, /* class_data */
47 NULL /* instance_init */
49 type = g_type_register_static (G_TYPE_INTERFACE, "MamanIbaz", &info, 0);
54 void maman_ibaz_do_action (MamanIbaz *self)
57 MAMAN_IBAZ_GET_INTERFACE (self)->do_action (self);
60 //that was the interface class
62 static void baz_do_action (MamanBaz *self)
64 self->instance_member = 10;
68 baz_interface_init (gpointer g_iface,
71 MamanIbazInterface *iface = (MamanIbazInterface *)g_iface;
72 iface->do_action = (void (*) (MamanIbaz *self))baz_do_action;
76 baz_instance_init (GTypeInstance *instance,
79 MamanBaz *self = MAMAN_BAZ(instance);
80 self->instance_member = 0xdeadbeaf;