Reputation: 2278
While compiling my app for iOS6 I get the following deprecation message:
From iOS 6 and later UITextAlignmentCenter is deprecated. Use NSTextAlignmentCenter instead.
Easy fix I thought, but it seems that NSTextAlignment is available in iOS 6.0 and later, and I also still want to support iOS 5. What is best practice to solve this problem?
Should I check which iOS the user is running and then use NSTextAlignment or UITextAlignment based on that?
Upvotes: 3
Views: 4008
Reputation: 41642
Deprecated means just that - its going away in the future. If it were me, I'd just wait til your app is going to be iOS6 or newer (I assume in the next year you will do that). Its extremely unlikely for Apple to remove it before Xcode stops supporting the older release its needed in.
Upvotes: 8