0

my issue can be seen in the below video:
https://www.dropbox.com/s/cql7r7b49lgffh9/navbarissue.mov

I have the following storyboard setup:enter image description here

To describe the problem in words...when the app loads it pushes revealviewcont>navcont>tabbarcont>navcont>firstviewcont. On the firstviewcont, the reveal menu button exists. Clicking this shows the slide out menu with numerous options in a table. Clicking the first cell returns you to the firstviewcont. However, when the firstviewcont is pushed from the menucont it creates a new navigation bar above the old one, thus rendering two nav bars. I assume this is because I'm going back through the stack, tabbarcont>navcont>firstviewcont. Attaching the segue to the firstview's nav controller is not supported, and attaching it to the firstviewcont does not display the Tab Bar.

I have tried hiding the navbar from viewwilldisappear and viewwillappear methods on the mentioned view controllers without success...how could I achieve returning to the firstviewcont while preserving the tab bar and displaying only one navigation bar?

jclark754
  • 914
  • 2
  • 12
  • 30

2 Answers2

1

I solved this question by....reading the changelog on the SWRevealViewController.h file.

- Took a cleaner approach to storyboard support. SWRevealViewControllerSegue is now 
deprecated and you should use SWRevealViewControllerSegueSetController and 
SWRevealViewControllerSeguePushController instead.

Changing my segues to the new version of storyboard segue fixed my issue.

Thanks for a great subclass John LLuch!

jclark754
  • 914
  • 2
  • 12
  • 30
0

I tried SWRevealViewControllerSegueSetController with identifier as "sw_front" and applied Embedded in navigationcontroller to view controller by removing old navigationcontroller then it works fine iOS 11. If you want navbar for front/center view add navcontroller to your view controller and connect segue to nav controller so that it displays nav bar either on front view or rear vc.