[vala] girwriter: Fix output of interface structs
- From: Jürg Billeter <juergbi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vala] girwriter: Fix output of interface structs
- Date: Tue, 1 Mar 2011 07:09:56 +0000 (UTC)
commit 6f5bf0eceda8f735a2f276d2e32ecf9477863929
Author: Michal Hruby <michal mhr gmail com>
Date: Mon Jan 31 18:20:33 2011 +0100
girwriter: Fix output of interface structs
codegen/valagirwriter.vala | 15 +++++++++++++++
1 files changed, 15 insertions(+), 0 deletions(-)
---
diff --git a/codegen/valagirwriter.vala b/codegen/valagirwriter.vala
index 60ab49e..55fc523 100644
--- a/codegen/valagirwriter.vala
+++ b/codegen/valagirwriter.vala
@@ -416,9 +416,24 @@ public class Vala.GIRWriter : CodeVisitor {
buffer.append_printf (">\n");
indent++;
+ write_indent ();
+ buffer.append_printf ("<field name=\"parent_iface\">\n");
+ indent++;
+ write_indent ();
+ buffer.append_printf ("<type name=\"GObject.TypeInterface\" c:type=\"GTypeInterface\"/>\n");
+ indent--;
+ write_indent ();
+ buffer.append_printf ("</field>\n");
+
foreach (Method m in iface.get_methods ()) {
if (m.is_abstract || m.is_virtual) {
+ write_indent ();
+ buffer.append_printf("<field name=\"%s\">\n", m.name);
+ indent++;
write_signature(m, "callback", true);
+ indent--;
+ write_indent ();
+ buffer.append_printf ("</field>\n");
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]