xzenon / LTNavigationBar

UINavigationBar Category which allows you to change its background dynamically

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

LTNavigationbar

It is hard to change the background color of UINavigationBar along with the status bar dynamically, so I made this lib to make the job easy.

LTNavigationbar

Usage

Step one:

#import "UINavigationBar+BackgroundColor.h"

Step two: update the background color wherever you want

[self.navigationController.navigationBar useBackgroundColor:[UIColor blueColor]];

Step three: in viewWillDisappear reset the nagivation bar

- (void)viewWillDisappear:(BOOL)animated
{
    [super viewWillDisappear:animated];
    [self.navigationController.navigationBar reset];
}

See the example for details~

About

UINavigationBar Category which allows you to change its background dynamically

License:MIT License


Languages

Language:Objective-C 93.6%Language:Ruby 6.4%