Segue location change creates black screen in ios simulator

I have no idea what is going on. In my interface builder, I had a segue pointing to the default view manager, and everything was fine. I added another view manager in IB, changed segue to point to it when the application starts, and now there is nothing in the ios simulator.

Any ideas? I have not changed the code.

+4
source share
1 answer

If you have a navigation controller (as the root controller), the first view controller in the stack must have a relation (the root view controller) from the navigation controller, otherwise your application will not know which view controller to load (first).

If the segment between the navigation controller and the first type controller is any other type of segue (push, modal, custom), the view controller does not load, and you will see a black (empty) window under the navigation panel.

If so, remove the segue between the navigation controller and the controller of the first view, then drag CTRL from the navigation controller to the first view controller, and for the type segue, select relationship .

+2
source

Source: https://habr.com/ru/post/1491181/


All Articles