diff options
author | Johan Dahlin <jdahlin@async.com.br> | 2008-04-25 23:50:02 +0000 |
---|---|---|
committer | Johan Dahlin <johan@src.gnome.org> | 2008-04-25 23:50:02 +0000 |
commit | 497c5eebcbf4af86ccca15aa87b4be28e76d638c (patch) | |
tree | 07c5de63d35f686f314d265b3e31ce08eeca9ce5 /tests | |
parent | 6296ff6bc14c00a016ce809e595f4c0a96750828 (diff) | |
download | gobject-introspection-497c5eebcbf4af86ccca15aa87b4be28e76d638c.tar.gz |
Add support for virtual methods. Pair struct FooClass with struct Foo.
2008-04-25 Johan Dahlin <jdahlin@async.com.br>
* TODO:
* giscanner/gidlwriter.py:
* giscanner/giscannermodule.c (pygi_source_directive_new),
(directive_get_options), (pygi_source_symbol_new),
(symbol_get_base_type), (pygi_source_type_new),
(type_get_base_type), (type_get_child_list),
(pygi_source_scanner_get_symbols),
(pygi_source_scanner_get_directives):
* giscanner/gobjecttreebuilder.py:
* giscanner/sourcescanner.py:
* giscanner/treebuilder.py:
* tests/parser/foo-object.h:
Add support for virtual methods.
Pair struct FooClass with struct Foo.
Clean up the SourceScanner bindings a bit.
Add a testcase for virtual methods.
svn path=/trunk/; revision=226
Diffstat (limited to 'tests')
-rw-r--r-- | tests/parser/Foo-expected.gidl | 7 | ||||
-rw-r--r-- | tests/parser/foo-object.h | 2 |
2 files changed, 9 insertions, 0 deletions
diff --git a/tests/parser/Foo-expected.gidl b/tests/parser/Foo-expected.gidl index 78554823..42592114 100644 --- a/tests/parser/Foo-expected.gidl +++ b/tests/parser/Foo-expected.gidl @@ -125,6 +125,13 @@ <parameter name="p1" type="gpointer"/> </parameters> </signal> + <vfunc name="virtual_method"> + <return-type type="gboolean"/> + <parameters> + <parameter name="object" type="FooObject*"/> + <parameter name="first_param" type="int"/> + </parameters> + </vfunc> </object> <object name="FooSubobject" parent="FooObject" type-name="FooSubobject" get-type="foo_subobject_get_type"> <constructor name="new" symbol="foo_subobject_new"> diff --git a/tests/parser/foo-object.h b/tests/parser/foo-object.h index b01034d2..8605f267 100644 --- a/tests/parser/foo-object.h +++ b/tests/parser/foo-object.h @@ -38,6 +38,8 @@ struct _FooObject struct _FooObjectClass { GObjectClass parent_class; + + gboolean (* virtual_method) (FooObject *object, int first_param); }; gint foo_init (void); |