ios - How to postpone [permission request alert]? -
my app requires these permissions
- notifications
- gps
- photos
the photos permission requested when user opens gallery, first 2 permissions show app app launch, it's okay me have gps first permission ask for, but want postpone notifications dialogue screen, how this?
this library seem not allow suggestions?
let notificationtypes : uiusernotificationtype = [uiusernotificationtype.alert,uiusernotificationtype.badge,uiusernotificationtype.sound] let notificationsettings = uiusernotificationsettings(fortypes: notificationtypes, categories: nil) application.registerforremotenotifications() application.registerusernotificationsettings(notificationsettings)
thanks, solves me,...
calling app delegate
let notificationtypes : uiusernotificationtype = [uiusernotificationtype.alert,uiusernotificationtype.badge,uiusernotificationtype.sound] let notificationsettings = uiusernotificationsettings(fortypes: notificationtypes, categories: nil) application.registerforremotenotifications() application.registerusernotificationsettings(notificationsettings)
calling class
let notificationtypes : uiusernotificationtype = [uiusernotificationtype.alert,uiusernotificationtype.badge,uiusernotificationtype.sound] let notificationsettings = uiusernotificationsettings(fortypes: notificationtypes, categories: nil) uiapplication.sharedapplication().registerforremotenotifications() uiapplication.sharedapplication().registerusernotificationsettings(notificationsettings)
Comments
Post a Comment