Different Navigation Bar Button Items in different child viewcontrollers from two container views?

故事扮演 提交于 2019-12-02 11:19:15

问题


I have setup a UIViewController(RootViewController) with two container views connected to two UITableViewControllers. Each of the UITableViewController is selected based on the UISegmentedControl in the RootViewController.

I'm able to segue as I intended to, but the bar button items in the child controllers (UITableViewController) are not responding.

The navigation bar button items in the two child view controllers are different from each other.

Please find a screenshot of my storyboard. (Only one child controller displayed)

How to setup different navigation bar buttons for each of those container view controllers?


回答1:


Did you push them on the UINavigation stack?

 func pushViewController(ViewController, animated: true)


来源:https://stackoverflow.com/questions/40101381/different-navigation-bar-button-items-in-different-child-viewcontrollers-from-tw

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!