iOS - 本地通知 - 显示的自定义设计

时间:2012-10-10 06:30:08

标签: ios jailbreak

enter image description here

如何在本地通知中显示自定义设计(显示图像)?

1 个答案:

答案 0 :(得分:0)

对于iOS,请查看UILocalNotification

UILocalNotification *localNotif = [[UILocalNotification alloc] init];
if (localNotif == nil) return;

localNotif.fireDate = someDate;
localNotif.timeZone = [NSTimeZone defaultTimeZone];

localNotif.alertBody = @"This is a custom message."
localNotif.alertAction = @"View Details";

localNotif.soundName = UILocalNotificationDefaultSoundName;
localNotif.applicationIconBadgeNumber = 1;

[[UIApplication sharedApplication] scheduleLocalNotification:localNotif];
[localNotif release];

在越狱中其他明智的选择可能是选择。

希望这会帮助你。