问题
I have a project that has to be deployed to 4.0 but has some features that are 5.0 only, such as UI customization.
I want my UIPopoverBackgroundView subclass to be weak linked, but I always get the following error when launching on 4.X devices
dyld: Symbol not found: _OBJC_CLASS_$_UIPopoverBackgroundView
I can't use the NS_CLASS_AVAILABLE macro since my custom Background of the popover is a subclass of the UIPopoverBackgroundView class, so it has to be declared in a .h . How can I weak link only part of UIKit? Or is there any other way around this issue?
Thanks to all
回答1:
After a lot of googling, turns out that Marco had the answer...
http://www.marco.org/2010/11/22/supporting-older-versions-of-ios-while-using-new-apis
来源:https://stackoverflow.com/questions/11428675/weak-linking-uipopoverbackgroundview