Open gilthonweapps opened 11 years ago
It doesn't work only when the view is not pushed inside a navigationcontroller.
My temp fix is bad (and really don't recommend unless you GOTTA have this working right). I stopped UI7 kit from handling my UINavigationBar, UINavigationController, and UINavigationItem. (remove those class names from UI7KitCore patch method).
And then in my App delegate appDidFinishLaunching method I'm just using [UINavigationBar appearance] methods to mimick the iOS7 look and feel. This is actually easier than you'd think because you can pretty much just use the same implementation that ui7Kit uses. For example, the back button :
UIImage *backImage = [UIImage imageNamed:@"UI7NavigationBarBackButton"];
backImage = [backImage imageByFilledWithColor:tintColor];
[[UIBarButtonItem appearance] setBackButtonBackgroundImage:backImage forState:UIControlStateNormal barMetrics:UIBarMetricsDefault];
backImage = [backImage imageByFilledWithColor:tintColor];
[[UIBarButtonItem appearance] setBackButtonBackgroundImage:backImage forState:UIControlStateHighlighted barMetrics:UIBarMetricsDefault];
I've got my tint color defined above and I also import #import "UIImage.h"
This is definitely only recommended if you are really having back button issues.
Hi,
If I change the "back" button of my navigation bar, it style uses the iOS6 layout.
Here is the code I use:
self.navigationItem.backBarButtonItem = [[UIBarButtonItem alloc] initWithTitle:NSLocalizedString(@"Back", nil) style:UIBarButtonItemStyleBordered target:nil action:nil];