robotmedia / RMStore

A lightweight iOS library for In-App Purchases
Apache License 2.0
2.43k stars 450 forks source link

Upgrade UIAlertView usage to UIAlertController for iOS 8 #124

Closed linusthe3rd closed 9 years ago

linusthe3rd commented 9 years ago

In iOS 8, UIAlertView has been deprecated and Apple recommends the use of UIAlertController instead.

This is not a huge problem, except in apps that support the upside-down orientation on iPhone (home button is at the top of the phone). When the app is in this position, the alert modal does not adjust its orientation.

screen shot 2014-12-06 at 5 13 50 pm

linusthe3rd commented 9 years ago

Since RMStore supports iOS versions before 8, I have personally had success so far with IDAlertController as a backwards-compatible implementation of UIAlertController. If running in iOS 7 or below, UIAlertView is used instead of UIAlertController.

hpique commented 9 years ago

@strife25 RMStore doesn't use UIAlertView*. If you see an alert by using it, that's coming from Apple code. And yes, I totally agree they should upgrade to UIAlertController. :)