[Kde-bindings] Qyoto test

Arno Rehn arno at arnorehn.de
Tue Dec 6 19:52:32 UTC 2005


Am Montag, 5. Dezember 2005 14:42 schrieb Richard Dale:
> On Monday 05 December 2005 12:38, Arno Rehn wrote:
> > FindMethod() className: QDialog MethodName: show
> >                 In FindMethodId QDialog::show => 2063
> > FindMethod() MethodName: show result: 2147
> > In CallMethod methodId: 2147 target: 0x0000000b items: 0
> > In CallMethod 136881448
> > In callMethod() fn: 0x415d7ff0 method().method: 15 ptr: (nil) _stack[1]:
> > 0
>
> Yes, it fails when calling the QDialog.Show() method because it doesn't yet
> save the C++ pointer of the new instance (ptr shouldn't be nil here, it
> should be the address of the QDialog created by the constructor). From the
> checkin log :
>
> * Constructor methods are now being called correctly, and the result is
> marshalled. However, ordinary
>   methods don't work because the instance variable '_smokeObject' is not
> being set up with a
>   pointer to the underlying C++ instance in the constructor.
Ok, that's clear.

> From Qt.cs:
>
> 	public class Qt : MarshalByRefObject, IDisposable {
> 		protected Object _interceptor = null;
>
> 		private IntPtr _smokeObject;
>  		protected Qt(Type dummy) {}
>
> I not sure why '_smokeObject' isn't an instance variable inside the
> SmokeInvocation though - maybe that should be changed.
>
> -- Richard

'_smokeObject' seems to be set up by 'SetSmokeObject' in SmokeInvocation.cs. 
The problem is that 'SetSmokeObject' is never called. The other problem is 
where do I get the C++ pointer to the instance when a new object is created?

-- 
MfG
Arno Rehn
arno at arnorehn.de



More information about the Kde-bindings mailing list