Skip to content

Commit

Permalink
JavaObjWrapper fix IntPtr result methods
Browse files Browse the repository at this point in the history
  • Loading branch information
olehkuznetsov committed Jan 18, 2019
1 parent 3c4d437 commit daad813
Showing 1 changed file with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -363,6 +363,10 @@ public T InvokeCall<T>(string name, string sig, params object[] args)
{
return (T)(object)AndroidJNI.CallShortMethod(raw, method, jArgs);
}
else if (t == typeof(IntPtr))
{
return (T)(object)AndroidJNI.CallObjectMethod(raw, method, jArgs);
}
else
{
return InvokeObjectCall<T>(name, sig, args);
Expand Down Expand Up @@ -428,6 +432,11 @@ public static T StaticInvokeCall<T>(string type, string name, string sig, params
return (T)(object)AndroidJNI.CallStaticShortMethod(
rawClass, method, jArgs);
}
else if (t == typeof(IntPtr))
{
return (T)(object)AndroidJNI.CallStaticObjectMethod(
rawClass, method, jArgs);
}
else
{
return StaticInvokeObjectCall<T>(type, name, sig, args);
Expand Down

0 comments on commit daad813

Please sign in to comment.