Local notification in Foreground

后端 未结 2 899
离开以前
离开以前 2021-01-18 16:55

in alarm ,notification works fine in background as follows:

    UILocalNotification *notification1=[[UILocalNotification alloc]init];
    notification1.fireD         


        
2条回答
  •  青春惊慌失措
    2021-01-18 17:45

    If the application is foremost and visible when the system delivers the notification, no alert is shown, no icon is badged, and no sound is played. However, the application:didReceiveLocalNotification: is called if the application delegate implements it. The UILocalNotification instance is passed into this method, and the delegate can check its properties or access any custom data from the userInfo dictionary.

提交回复
热议问题