Last active
November 4, 2015 20:18
-
-
Save mrakowski/4003093 to your computer and use it in GitHub Desktop.
Check iOS selector availability
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Check for the existence of a selector | |
if ([_pageControl respondsToSelector:@selector(pageIndicatorTintColor)] == YES) { | |
} | |
// Check device system version | |
+ (BOOL)isRunningiOS5 { | |
// This will only return true in iOS 5 and up. | |
if ([[[UIDevice currentDevice] systemVersion] floatValue] >= 5.0f) { | |
return YES; | |
} else { | |
return NO; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment