Add support for foreign structs

Foreign structs are special in the sense that there might
be native bindings (for instance PyCairo for PyGI) that provides
the same functionallity as the introspected variant.

https://bugzilla.gnome.org/show_bug.cgi?id=610357
This commit is contained in:
Johan Dahlin 2010-03-25 23:12:12 -03:00 committed by Philip Withnall
parent 567a6d2195
commit 320dd66c62

View File

@ -606,6 +606,7 @@ write_struct_info (const gchar *namespace,
const gchar *type_init;
gboolean deprecated;
gboolean is_gtype_struct;
gboolean foreign;
gint i;
gint size;
int n_elts;
@ -643,6 +644,10 @@ write_struct_info (const gchar *namespace,
if (show_all && size >= 0)
xml_printf (file, " size=\"%d\"", size);
foreign = g_struct_info_is_foreign (info);
if (foreign)
xml_printf (file, " foreign=\"1\"");
n_elts = g_struct_info_get_n_fields (info) + g_struct_info_get_n_methods (info);
if (n_elts > 0)
{