Support the (transfer) annotation for properties.

* girepository/*: Add g_property_info_get_ownership_transfer() and write
  the transfer attribute of properties into the typelib.

* giscanner/*: Parse the (transfer) annotation and write it into the .gir.

* tools/generate.c: Read the transfer annotation for properties and write
  to the .tgir.

https://bugzilla.gnome.org/show_bug.cgi?id=620484
This commit is contained in:
Tomeu Vizoso
2010-06-08 16:40:35 +02:00
parent b2575e8210
commit 518765acf3
8 changed files with 134 additions and 40 deletions

View File

@@ -1648,6 +1648,8 @@ g_ir_node_build_typelib (GIrNode *node,
blob->writable = prop->writable;
blob->construct = prop->construct;
blob->construct_only = prop->construct_only;
blob->transfer_ownership = prop->transfer;
blob->transfer_container_ownership = prop->shallow_transfer;
blob->reserved = 0;
g_ir_node_build_typelib ((GIrNode *)prop->type,