标签:unity android local notification 陈小道 notification.builder
AndroidJavaObject nativeObj = new AndroidJavaObject("com.macaronics.notification.AlarmReceiver"); nativeObj.CallStatic("startAlarm", new object[5]{title,title, msg, secondsFromNow, triggerTimeInt});参数的含义:
AndroidJavaObject playerActivityContext = null; using (var actClass = new AndroidJavaClass("com.unity3d.player.UnityPlayer")) { playerActivityContext = actClass.GetStatic<AndroidJavaObject>("currentActivity"); } using (AndroidJavaClass javaClass = new AndroidJavaClass("com.macaronics.notification.AlarmReceiver")) { javaClass.CallStatic("clearNotification",playerActivityContext); }
Unity Android Local Notification
标签:unity android local notification 陈小道 notification.builder
原文地址:http://blog.csdn.net/cdztop/article/details/39699675