ios - Issue with a UINavigationController inside a UITabBarController inside another UINavigationController -


don't ask me show code because there's no code. has been done in storyboard.

my app starts main navigation controller holds login view controller root view controller. login view controller has button. when button pressed tab bar controller pushed. tab bar controller has 4 items. each item secondary navigation controller maintaining own stack of view controllers. structure is: main uinavigationcontroller-> login view controller -> uitabbarcontroller -> secondary uinavigationcontroller -> array of view controllers.

the problem is: when way along stack of secondary navigation controller's view controllers previous view controller pressing back button on navigation bar. turns out navigation bar belongs not current navigation controller (the secondary one)! belongs main navigation controller! when tap back button pop beginning of app, login view controller because main navigation controller pops tab bar controller. hope described issue clearly.

of course can workaround. if hide main navigation controller's navigation bar i'm presented secondary navigation controller's navigation bar need. feel not proper solution. feel there must right one. think, guys?

i wouldn't recommend using uinavigationcontroller segue login main uitabbarcontroller... personally, prefer have different rootviewcontroller of main uiwindow login or presenting login modally (without animation)... makes more sense, since don't expect user "navigate back" login screen, rather use logout , switch context completely.


Comments

Popular posts from this blog

Magento/PHP - Get phones on all members in a customer group -

php - Bypass Geo Redirect for specific directories -

php - .htaccess mod_rewrite for dynamic url which has domain names -