1
votes

In my iPad app, I have my main interface as a UISplitViewController with a tableView as the master and a UIView as the detail. Both have navigation bars. In my detail view, I have two buttons, both of which Show segue to their own UIViews. Currently, the Show segues replace the detail view and provide a back button to return to the original detail view.
This is the behavior I desire for ONE of the segues. For the other, I want it to present over the entire UISplitView controller and take up the whole screen. I also need the navigation bar to stay on this view and provide a back button action to get back to the UISplitView. I have tried presenting the view Modally, and it does take up the whole screen, but this doesn't seem to play well with navigation bars. How can I accomplish this, either programmatically or with Storyboard?

1
When you say your modally presented view "doesn't play well with navigation bars" what do you mean?Scott Thompson
You can add a Navigation Bar, along with any buttons you wish, without needing a UINavigationController. Try just adding one to your "whole screen" view. Once you see how it shows up, then add an appropriate "Done" or "Finished" or "Back" or whatever button to it.DonMag
@ScottThompson I mean that the navigation bar doesn't appear in views presented modally.Timestretch
Ah! Ok. You can create your own navigation bar (UINavigationBar) inside your modally presented view and set it up to mock the real navigation bar. Then when the user hits the "Back" button just end the modal session.Scott Thompson
@ScottThompson is there a way to mimic the same transition animations instead of the modal ones?Timestretch

1 Answers

0
votes

Easiest will be to select your ViewController in the storyboard and embed it in Navigation controller and then try to present the navigation controller you will have a navigation bar att the top