Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
// Fixed iOS 7 backButtonBackground issue.
if ([[UIDevice currentDevice].systemVersion compare:@"7.0" options:NSNumericSearch] != NSOrderedAscending) {
[[UINavigationBar appearance] setTintColor:[UIColor whiteColor]];
[[UINavigationBar appearance] setBackIndicatorImage:[UIImage imageNamed:@"BackButtonIcon"]];
} else {
UIImage *backButtonBackground = [[UIImage imageNamed:@"BackButtonIcon"] resizableImageWithCapInsets:UIEdgeInsetsMake(0, 29, 0, 0)];
[[UIBarButtonItem appearance] setBackButtonBackgroundImage:backButtonBackground forState:UIControlStateNormal barMetrics:UIBarMetricsDefault];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.