| 272 GType |
272 GType |
| 273 purple_plugin_register_type(PurplePlugin *plugin, GType parent, |
273 purple_plugin_register_type(PurplePlugin *plugin, GType parent, |
| 274 const gchar *name, const GTypeInfo *info, |
274 const gchar *name, const GTypeInfo *info, |
| 275 GTypeFlags flags) |
275 GTypeFlags flags) |
| 276 { |
276 { |
| 277 g_return_val_if_fail(G_TYPE_MODULE(plugin), G_TYPE_INVALID); |
277 g_return_val_if_fail(G_IS_TYPE_MODULE(plugin), G_TYPE_INVALID); |
| 278 |
278 |
| 279 return g_type_module_register_type(G_TYPE_MODULE(plugin), |
279 return g_type_module_register_type(G_TYPE_MODULE(plugin), |
| 280 parent, name, info, flags); |
280 parent, name, info, flags); |
| 281 } |
281 } |
| 282 |
282 |
| 283 void |
283 void |
| 284 purple_plugin_add_interface(PurplePlugin *plugin, GType instance_type, |
284 purple_plugin_add_interface(PurplePlugin *plugin, GType instance_type, |
| 285 GType interface_type, |
285 GType interface_type, |
| 286 const GInterfaceInfo *interface_info) |
286 const GInterfaceInfo *interface_info) |
| 287 { |
287 { |
| 288 g_return_if_fail(G_TYPE_MODULE(plugin)); |
288 g_return_if_fail(G_IS_TYPE_MODULE(plugin)); |
| 289 |
289 |
| 290 g_type_module_add_interface(G_TYPE_MODULE(plugin), |
290 g_type_module_add_interface(G_TYPE_MODULE(plugin), |
| 291 instance_type, interface_type, |
291 instance_type, interface_type, |
| 292 interface_info); |
292 interface_info); |
| 293 } |
293 } |