objective c - iOS logic for presenting login button or actual content in a VC -


right have 2 uiview container @ same hierarchy, one containing login button (that modally presents login vc) , the other containing actual content. logic show these views corresponds following code:

loginview.hidden = islogged actualview.hidden = !islogged 

these work, makes hard work on interface builder, each time i'm modifying underlying view, have move front 1 , constraint messed up.

is there way same behaviour instead of overlapping 2 views .hidden = true/false, managed controller or similar? (i.e: if logged present actual vc, else present vc login button)

is there way same behaviour instead of overlapping 2 views .hidden = true/false, managed controller or similar? (i.e: if logged present actual vc, else present vc login button)

yes. can move login view nib load in code. still have either show , hide, or load , unload nib needed; however, doing way remove clutter storyboard.


Comments

Popular posts from this blog

android - MPAndroidChart - How to add Annotations or images to the chart -

javascript - Add class to another page attribute using URL id - Jquery -

firefox - Where is 'webgl.osmesalib' parameter? -