Last active
December 25, 2015 04:49
-
-
Save futuretap/6920492 to your computer and use it in GitHub Desktop.
Logs iOS device color and device enclosure color. Attention: private API, do not use in App Store builds!
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
UIDevice *device = [UIDevice currentDevice]; | |
SEL selector = NSSelectorFromString([device.systemVersion hasPrefix:@"7"] ? @"_deviceInfoForKey:" : @"deviceInfoForKey:"); | |
NSLog(@"DeviceColor: %@ DeviceEnclosureColor: %@", [device performSelector:selector withObject:@"DeviceColor"], [device performSelector:selector withObject:@"DeviceEnclosureColor"]); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment