下面的代码用来打开另一个视图控制器 (在myviewcontroller1.m中):
#import "contactvc.h"
contactvc *ii;
// ....
-(IBAction)passothervc:(id)sender
{
//this code seems working OK.
ii = [self.storyboard instantiateViewControllerWithIdentifier:@"contactvc"];
[self presentViewController:ii animated:NO completion:nil];
}
下面的代码返回给主视图控制器:
-(IBAction)backToMain:(id)sender
{
[self.view removeFromSuperview];
}
问题是在按后退键时会保持空黑屏幕。请指教。