What happens to root view controller in ios / swift -


say switching viewcontrollers manually how transition new view controller code using swift

what happens (root) controller when viewcontroller brought front. can reinstantiate or should keep reference pu front?

no don't have re-instantiate it. can access current uiviewcontrollers uinavigationcontroller this

self.navigationcontroller?.viewcontrollers 

this return [uiviewcontroller]. if want viewcontroller @ index = 0. if want root can call

self.navigationcontroller?.poptorootviewcontrolleranimated(true) 

Comments

Popular posts from this blog

routing - AngularJS State management ->load multiple states in one page -

python - GRASS parser() error -

post - imageshack API cURL -