Created
September 25, 2014 00:04
-
-
Save bithavoc/303044f7224ccb0be1a8 to your computer and use it in GitHub Desktop.
Fix iOS8 UI datepicker issue.
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
// https://medium.com/@bithavoc/uidatepicker-presentation-issue-on-ios-8-98215118a27f | |
if(NSFoundationVersionNumber > NSFoundationVersionNumber_iOS_7_1) { | |
[[UITableView appearanceWhenContainedIn:[UIDatePicker class], nil] setBackgroundColor:nil]; // for iOS 8 | |
} else { | |
[[UITableViewCell appearanceWhenContainedIn:[UIDatePicker class], [UITableView class], nil] setBackgroundColor:[UIColor colorWithWhite:0.0 alpha:0.0]]; // for iOS 7 | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment