Loading README.md +2 −1 Changes for README.md: 2 added lines, 1 removed line. Original line number Diff line number Diff line Loading @@ -54,6 +54,7 @@ More informations can be found [here](https://build.phonegap.com/plugins/413). - [bugfix:] cancel callbacks have not been fired after all notifications have been canceled on iOS. - [change:] The `oncancel` callback will be called at last if `autoCancel` is set to true (iOS). - [bugfix:] Callbacks for non-repeating notifications were not called if they were not created in the current app instance on iOS. - [enhancement:] Added 'secondly' and 'minutely' as new repeat time aliases. #### Version 0.7.2 (09.02.2014) - [enhancement:] Avoid blocking the main thread (on Android) **(dpogue)**. Loading Loading @@ -141,7 +142,7 @@ window.plugin.notification.local.add({ date: Date, // This expects a date object message: String, // The message that is displayed title: String, // The title of the message repeat: String, // Has the options of 'hourly', 'daily', 'weekly', 'monthly', 'yearly' repeat: String, // Has the options of 'secondly', 'minutely', 'hourly', 'daily', 'weekly', 'monthly', 'yearly' badge: Number, // Displays number badge to notification sound: String, // A sound to be played json: String, // Data to be passed through the notification Loading src/android/Options.java +5 −1 Changes for src/android/Options.java: 5 added lines, 1 removed line. Original line number Diff line number Diff line Loading @@ -58,7 +58,11 @@ public class Options { this.options = options; if (repeat.equalsIgnoreCase("hourly")) { if (repeat.equalsIgnoreCase("secondly")) { interval = 1000; } if (repeat.equalsIgnoreCase("minutely")) { interval = AlarmManager.INTERVAL_FIFTEEN_MINUTES / 15; } if (repeat.equalsIgnoreCase("hourly")) { interval = AlarmManager.INTERVAL_HOUR; } if (repeat.equalsIgnoreCase("daily")) { interval = AlarmManager.INTERVAL_DAY; Loading src/ios/APPLocalNotification.m +4 −0 Changes for src/ios/APPLocalNotification.m: 4 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -199,12 +199,16 @@ NSString *const kAPP_LOCALNOTIFICATION = @"APP_LOCALNOTIFICATION"; NSMutableDictionary* repeatDict = [[NSMutableDictionary alloc] init]; #ifdef NSCalendarUnitHour [repeatDict setObject:[NSNumber numberWithInt:NSCalendarUnitSecond] forKey:@"secondly"]; [repeatDict setObject:[NSNumber numberWithInt:NSCalendarUnitMinute] forKey:@"minutely"]; [repeatDict setObject:[NSNumber numberWithInt:NSCalendarUnitHour] forKey:@"hourly"]; [repeatDict setObject:[NSNumber numberWithInt:NSCalendarUnitDay] forKey:@"daily"]; [repeatDict setObject:[NSNumber numberWithInt:NSWeekCalendarUnit] forKey:@"weekly"]; [repeatDict setObject:[NSNumber numberWithInt:NSCalendarUnitMonth] forKey:@"monthly"]; [repeatDict setObject:[NSNumber numberWithInt:NSCalendarUnitYear] forKey:@"yearly"]; #else [repeatDict setObject:[NSNumber numberWithInt:NSSecondCalendarUnit] forKey:@"secondly"]; [repeatDict setObject:[NSNumber numberWithInt:NSMinuteCalendarUnit] forKey:@"minutely"]; [repeatDict setObject:[NSNumber numberWithInt:NSHourCalendarUnit] forKey:@"hourly"]; [repeatDict setObject:[NSNumber numberWithInt:NSDayCalendarUnit] forKey:@"daily"]; [repeatDict setObject:[NSNumber numberWithInt:NSWeekCalendarUnit] forKey:@"weekly"]; Loading Loading
README.md +2 −1 Changes for README.md: 2 added lines, 1 removed line. Original line number Diff line number Diff line Loading @@ -54,6 +54,7 @@ More informations can be found [here](https://build.phonegap.com/plugins/413). - [bugfix:] cancel callbacks have not been fired after all notifications have been canceled on iOS. - [change:] The `oncancel` callback will be called at last if `autoCancel` is set to true (iOS). - [bugfix:] Callbacks for non-repeating notifications were not called if they were not created in the current app instance on iOS. - [enhancement:] Added 'secondly' and 'minutely' as new repeat time aliases. #### Version 0.7.2 (09.02.2014) - [enhancement:] Avoid blocking the main thread (on Android) **(dpogue)**. Loading Loading @@ -141,7 +142,7 @@ window.plugin.notification.local.add({ date: Date, // This expects a date object message: String, // The message that is displayed title: String, // The title of the message repeat: String, // Has the options of 'hourly', 'daily', 'weekly', 'monthly', 'yearly' repeat: String, // Has the options of 'secondly', 'minutely', 'hourly', 'daily', 'weekly', 'monthly', 'yearly' badge: Number, // Displays number badge to notification sound: String, // A sound to be played json: String, // Data to be passed through the notification Loading
src/android/Options.java +5 −1 Changes for src/android/Options.java: 5 added lines, 1 removed line. Original line number Diff line number Diff line Loading @@ -58,7 +58,11 @@ public class Options { this.options = options; if (repeat.equalsIgnoreCase("hourly")) { if (repeat.equalsIgnoreCase("secondly")) { interval = 1000; } if (repeat.equalsIgnoreCase("minutely")) { interval = AlarmManager.INTERVAL_FIFTEEN_MINUTES / 15; } if (repeat.equalsIgnoreCase("hourly")) { interval = AlarmManager.INTERVAL_HOUR; } if (repeat.equalsIgnoreCase("daily")) { interval = AlarmManager.INTERVAL_DAY; Loading
src/ios/APPLocalNotification.m +4 −0 Changes for src/ios/APPLocalNotification.m: 4 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -199,12 +199,16 @@ NSString *const kAPP_LOCALNOTIFICATION = @"APP_LOCALNOTIFICATION"; NSMutableDictionary* repeatDict = [[NSMutableDictionary alloc] init]; #ifdef NSCalendarUnitHour [repeatDict setObject:[NSNumber numberWithInt:NSCalendarUnitSecond] forKey:@"secondly"]; [repeatDict setObject:[NSNumber numberWithInt:NSCalendarUnitMinute] forKey:@"minutely"]; [repeatDict setObject:[NSNumber numberWithInt:NSCalendarUnitHour] forKey:@"hourly"]; [repeatDict setObject:[NSNumber numberWithInt:NSCalendarUnitDay] forKey:@"daily"]; [repeatDict setObject:[NSNumber numberWithInt:NSWeekCalendarUnit] forKey:@"weekly"]; [repeatDict setObject:[NSNumber numberWithInt:NSCalendarUnitMonth] forKey:@"monthly"]; [repeatDict setObject:[NSNumber numberWithInt:NSCalendarUnitYear] forKey:@"yearly"]; #else [repeatDict setObject:[NSNumber numberWithInt:NSSecondCalendarUnit] forKey:@"secondly"]; [repeatDict setObject:[NSNumber numberWithInt:NSMinuteCalendarUnit] forKey:@"minutely"]; [repeatDict setObject:[NSNumber numberWithInt:NSHourCalendarUnit] forKey:@"hourly"]; [repeatDict setObject:[NSNumber numberWithInt:NSDayCalendarUnit] forKey:@"daily"]; [repeatDict setObject:[NSNumber numberWithInt:NSWeekCalendarUnit] forKey:@"weekly"]; Loading