I currently have three view controllers going on in my iPhone application at the same time.
I use a slidingView.
Here is my image:
When I tap on a table view cell, I want to open a new view controller like this:
(the egg is representing a new view controller.
But as you can see my orange view controller is in front.
How do I change this?
The code I use to open the egg-viewcontroller
:
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
{
UIViewController *boxView = [self.storyboard instantiateViewControllerWithIdentifier:@"BoxView"];
boxView.modalPresentationStyle = UIModalPresentationFormSheet;
boxView.modalTransitionStyle = UIModalTransitionStyleCoverVertical;
boxView.view.frame=CGRectMake(-50, 5, 300, 470);
[self.view addSubview:boxView.view];
//[self.view bringSubviewToFront:boxView];
}