예제 #1
0
    /// <summary>
    /// 通知をキャンセルする。
    /// </summary>
    /// <param name="notificationId">通知Id。</param>
    static public void CancelNotification(int notificationId)
    {
#if UNITY_ANDROID
        AndroidNotificationController.CancelAndroidNotificationIfScheduled(notificationId);
#elif UNITY_IOS
        IOSNotificationController.CancelIOSNotificationIfScheduled(notificationId.ToString());
#endif
    }
예제 #2
0
    /// <summary>
    /// 通知をキャンセルする。
    /// </summary>
    /// <param name="notificationType">通知タイプ。</param>
    static public void CancelNotification(Notifications notificationType)
    {
        var notificationId = ToIdNotifications(notificationType);

#if UNITY_ANDROID
        AndroidNotificationController.CancelAndroidNotificationIfScheduled(notificationId);
#elif UNITY_IOS
        IOSNotificationController.CancelIOSNotificationIfScheduled(notificationId.ToString());
#endif
    }