ios - How to do a replace segue on an iPhone? -
i want change between 2 view controllers using button, on iphone. don't want use uitabbarcontroller because takes space, want same kind of segue. how do that? need write custom segue ?
a push segue want operation can reversed allowing button (or stepper) dictate navigation.
to initiate;
[self performseguewithidentifier:@"destinationviewcontroller" sender:self];
to return either use button appear in navigation bar or programmatically hidden button.
[self.navigationcontroller popviewcontrolleranimated:yes];
to hide button:
self.navigationitem.hidesbackbutton = yes;
called in -(void)viewwillappear part of lifecycle.
Comments
Post a Comment