Commit 30ef6817 by Sebastián Katzer

Use localNotifications: instead of scheduledLocalNotifications:

parent 121ab4ac
...@@ -293,7 +293,7 @@ ...@@ -293,7 +293,7 @@
* The IDs of the notifications * The IDs of the notifications
*/ */
- (void) getIds:(CDVInvokedUrlCommand*)command - (void) getIds:(CDVInvokedUrlCommand*)command
byType:(APPLocalNotificationType)type; byType:(APPLocalNotificationType)type;
{ {
[self.commandDelegate runInBackground:^{ [self.commandDelegate runInBackground:^{
CDVPluginResult* result; CDVPluginResult* result;
...@@ -410,7 +410,7 @@ ...@@ -410,7 +410,7 @@
- (void) registerPermission:(CDVInvokedUrlCommand*)command - (void) registerPermission:(CDVInvokedUrlCommand*)command
{ {
if ([[UIApplication sharedApplication] if ([[UIApplication sharedApplication]
respondsToSelector:@selector(registerUserNotificationSettings:)]) respondsToSelector:@selector(registerUserNotificationSettings:)])
{ {
_command = command; _command = command;
...@@ -493,11 +493,11 @@ ...@@ -493,11 +493,11 @@
{ {
NSArray* notifications; NSArray* notifications;
notifications = [self.app scheduledLocalNotifications]; notifications = [self.app localNotifications];
for (UILocalNotification* notification in notifications) for (UILocalNotification* notification in notifications)
{ {
if (notification && ![notification isRepeating] if (![notification isRepeating]
&& notification.timeIntervalSinceFireDate > seconds) && notification.timeIntervalSinceFireDate > seconds)
{ {
[self.app cancelLocalNotification:notification]; [self.app cancelLocalNotification:notification];
...@@ -636,8 +636,8 @@ ...@@ -636,8 +636,8 @@
} }
/** /**
* Simply invokes the callback without any parameter. * Simply invokes the callback without any parameter.
*/ */
- (void) execCallback:(CDVInvokedUrlCommand*)command - (void) execCallback:(CDVInvokedUrlCommand*)command
{ {
CDVPluginResult *result = [CDVPluginResult CDVPluginResult *result = [CDVPluginResult
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment