[Mono-list] embedding mono and returning GList
Robert Jordan
robertj at gmx.net
Sun May 22 14:44:03 EDT 2011
On 22.05.2011 15:05, Nils Andresen wrote:
> 2011/5/22 Miguel de Icaza<miguel at xamarin.com>:
>> What you are getting back is not a pointer to the C GList, but a pointer to
>> the managed GList; What you need to do is return the unmanaged pointer
>> that is wrapped by the C# GList, that would be the GList.Handle.
>> Miguel
>
> Thanks Miguel,
> I tried this. I am currently casting the returned MonoObject (the
> IntPtr now..) directly to GList. This does not work, however. Any more
> hints ?
You must unbox the returned object. See mono_object_unbox().
Robert
More information about the Mono-list
mailing list