如果我的应用程序已打开且我收到推送通知,则警报只有一个操作 - “确定”。是否可以添加另一个动作,类似于我如何为UIAlertController执行如下操作?
let alert = UIAlertController(title: title, message: message, preferredStyle: UIAlertControllerStyle.Alert)
alert.addAction(UIAlertAction(title: "Second Action", style: .Default, handler: { (action) -> Void in
}))
更新:我一直在环顾四周,看来你不能这样做
答案 0 :(得分:0)
您可以在Appdelegate.m
- application: didReceiveRemoteNotification:
只需在此处实施您的代码。
答案 1 :(得分:0)
在[PFPush handlePush:userInfo];
中评论此- application: didReceiveRemoteNotification:
方法,并提供问题中提到的自定义提醒视图。