Michael B. Trausch wrote: > On Sat, 11 Jul 2009, Michael 'Mickey' Lauer wrote: >> >> Thanks, that's slightly better, still I'd love to have a classical >> constructor >> way of creating a context, like: >> >> var c = new Canberra.Context(); >> >> Is this impossible without changes in the library itself? >> > > You can (with a bit of work) create APIs that are more object-oriented. > You have to do a bit of extra work, though, and the function has to > return a pointer to a structure (at least, AFAIK).
In this case the problem is that the function returns the newly constructed object as 'out' parameter, not as return value. AFAIK there is no 'CCode' attribute for telling Vala to treat an 'out' parameter as return value. Best Regards, Frederik _______________________________________________ Vala-list mailing list [email protected] http://mail.gnome.org/mailman/listinfo/vala-list
