iOS 8: Corona apps ask for Push Notification approval

Now we just need to control, when the application asks for permission instead of first launch.

It needs to wait asking for permission until the app is in a context where it makes sense please :slight_smile:

@ingemar, This was talked about at WWDC (at least in the one on one not sure about if it made it to the public or not) as one of the new changes to notifications because of all the local notification spam.

@thassman, Apple has and will never wait for an application to load fully before asking the end user for permissions :slight_smile:

That is not correct, the app prompts you whenever the app invokes registerForRemoteNotificationTypes 

Yes most apps do that in the apps didFinishLaunchingWithOptions method (at launch time), but if you code natively you are in control when to invoke it.

It is imho getting more and more needed, to provide user with context, as people are fed up with spamming apps and just denies push.

@Christopher
Thanks for confirming the issue.
As I mentioned above, it makes sense that they implemented approval even for local push.

I’m leaning towards removing it from my games now since I think that some users might be reluctant to install a game that asks for such a permission if there is no beneficial reason to have it. Besides, I only implemented it as a one-time reminder to the user after 21 days of inactivity.

registerForRemoteNotificationTypes is no longer supported in IOS8 and while it is true you can call launchingOptions in all my testing “with native applications” in IOS8 I have not found a way around the permission alert when app loads.

Of course I could be missing something :slight_smile:

Never tried it with iOS8, gotta look into it, thanks for heads up  :slight_smile:

How do you ask for permission for local notifications? My iOS app is not asking for permissions and it’s not showing the local notifications. 

I’m testing on an iPad with iOS 8 and the app was build with iOS SDK 7.1

If you need notifications, build with the iOS 7.1 SDK, until we have time to sort all of this out.

Rob

I’m building with the iOS 7.1 SDK, but my testing device is running iOS 8. 

iOS 8 should not force new rules on iOS 7 apps.  Are you getting any errors? 

Rob

The log says that I need to ask the user’s permission to schedule notifications, is there a way to do that?

What version are you building with? 

The release notes for 2014.2438 has this entry:

  • iOS: Fix local notifications for iOS 8.

2439 addresses an issue with Location services (GPS and Maps).  Make sure you’re using the latest daily build.

Rob

Ok, maybe is that, I’m on Corona 2014.2428. Let me update and see if it helps. Thanks. 

Hi folks,

This has been implemented and is in build 2015.2542.  You can read more about it in the blog here: http://coronalabs.com/blog/2015/01/21/notifications-have-been-moved-to-a-plugin/

Hi folks,

This has been implemented and is in build 2015.2542.  You can read more about it in the blog here: http://coronalabs.com/blog/2015/01/21/notifications-have-been-moved-to-a-plugin/