- Notifications
You must be signed in to change notification settings - Fork1.3k
Added custom navigationBarClass support to NavigationController#1079
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Added custom navigationBarClass support to NavigationController#1079
Uh oh!
There was an error while loading.Please reload this page.
Conversation
phlippieb commentedMay 25, 2018 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
Two other ways I can think of doing this are:
If you prefer either of those, I'll update my PR. |
OrkhanAlikhanov commentedJun 2, 2018
Hey@phlippieb , thank you for your contribution. I would go with your first option. Which I guess what you meant should look like this, but with 2-spaced indention just like other parts of the file: publicoverrideconvenienceinit(rootViewController:UIViewController){self.init(rootViewController: rootViewController, navigationBarClass:NavigationBar.self)}publicinit(rootViewController:UIViewController, navigationBarClass:AnyClass?){ super.init(navigationBarClass: navigationBarClass, toolbarClass:nil)setViewControllers([rootViewController], animated:false)} If@DanielDahan approves either option, You may remove the commit rebase development branch again and reapply changes and do one clean commit. To be honest, I am not sure about the second option. |
daniel-jonathan left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Thank you!
Uh oh!
There was an error while loading.Please reload this page.
#1074
Adds an initializer to NavigationController that takes a custom navigation bar class parameter; this parameter is simply passed to super.
This extends NavigationController with the ability to be initialized with a user-defined subclass of NavigationBar.