Seesi / JitsiMeet.Xamarin.IOS

A xamarin ios wrapper library of JitsiMeetIOS SDK
6 stars 3 forks source link

CallKit support #12

Open andreipro1002 opened 2 years ago

andreipro1002 commented 2 years ago

Hello,

I'm trying to use the binding code from ApiDefinitions.cs for the interfaces JMCallKitProxy and JMCallKitListener (the code is commented) and I get a crash with message: "Method not found: void JMCallKitProxy.AddListener(JMCallKitListener)".

I have access to an older Jitsi iOS library .dll (CallKit works on this one) and I noticed in assembly browser that the method AddListener from JMCallKitProxy should have IJMCallKitListener as parameter instead of JMCallKitListener.

[Export ("addListener:")]
[BindingImpl (BindingImplOptions.GeneratedCode | BindingImplOptions.Optimizable)]
public static void AddListener (IJMCallKitListener listener);

It seems that IJMCallKitListener is generated in assemblies, but I don't know how to use it in ApiDefinitions for it to work. Do you have any idea? Thanks in advance.

andreipro1002 commented 2 years ago

I solved this by adding in ApiDefinition.cs: interface IJMCallKitListener { }

And use it in the methods AddListener and RemoveListener from JMCallKitProxy: void AddListener(IJMCallKitListener listener); void RemoveListener(IJMCallKitListener listener);