-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove Application namespace in AndroidCallBack class
- Loading branch information
Showing
3 changed files
with
19 additions
and
25 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,34 +1,30 @@ | ||
using System; | ||
using UnityEngine; | ||
using UnityEngine; | ||
|
||
namespace Application | ||
public class AndroidPluginCallback : AndroidJavaProxy | ||
{ | ||
public class AndroidPluginCallback : AndroidJavaProxy | ||
{ | ||
public delegate void OnSuccessEvent(AndroidJavaObject count); | ||
public delegate void onErrorEvent(AndroidJavaObject exception); | ||
public delegate void OnSuccessEvent(AndroidJavaObject count); | ||
public delegate void onErrorEvent(AndroidJavaObject exception); | ||
|
||
public event OnSuccessEvent OnSuccess; | ||
public event onErrorEvent OnError; | ||
public event OnSuccessEvent OnSuccess; | ||
public event onErrorEvent OnError; | ||
|
||
public AndroidPluginCallback() : base("com.adpdigital.push.Callback") { } | ||
public AndroidPluginCallback() : base("com.adpdigital.push.Callback") { } | ||
|
||
private void onSuccess(AndroidJavaObject count) | ||
private void onSuccess(AndroidJavaObject count) | ||
{ | ||
if (OnSuccess != null) | ||
{ | ||
if (OnSuccess != null) | ||
{ | ||
OnSuccess.Invoke(count); | ||
} | ||
Debug.Log("ENTER callback onSuccess: " + count); | ||
OnSuccess.Invoke(count); | ||
} | ||
Debug.Log("ENTER callback onSuccess: " + count); | ||
} | ||
|
||
public void onError(AndroidJavaObject exception) | ||
public void onError(AndroidJavaObject exception) | ||
{ | ||
if (OnError != null) | ||
{ | ||
if (OnError != null) | ||
{ | ||
OnError.Invoke(exception); | ||
} | ||
Debug.Log("ENTER callback onError: " + exception); | ||
OnError.Invoke(exception); | ||
} | ||
Debug.Log("ENTER callback onError: " + exception); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters