我有一个拆分视图控制器,我将其作为子视图添加到一个虚拟视图控制器,然后我模态地在我的 viewController 顶部呈现虚拟视图控制器。它工作正常,直到这里:代码:
ContactsViewController *contactsViewController = [[ContactsViewController alloc]init];
UINavigationController *navController = [[UINavigationController alloc]
initWithRootViewController:contactsViewController];
MasterViewController* masterViewController = [[MasterViewController alloc]init];
UINavigationController *masterNavigationController = [[[UINavigationController alloc]
initWithRootViewController:masterViewController] autorelease];
self.splitViewController.viewControllers = @[masterNavigationController,
navController];
UIViewController *dummyView = [[UIViewController alloc]init];
[dummyView.view addSubview:self.splitViewController.view];
self.splitViewController.delegate = detailViewController;
[self.navigationController presentModalViewController:dummyView animated:YES];
[contactsViewController release];
[navController release];
现在,当我尝试关闭出现的 splitView 控制器(或虚拟视图)时,问题就出现了,无论我做什么,它都不起作用..任何想法都将不胜感激......