我在 iOS8 中使用 UIActionSheet(我的应用程序需要支持 iOS7),但看起来在 iOS8 下,UIActionSheet 保留了视图!我制作了一个简单的应用程序,其中在导航视图控制器 ViewController1 和 ViewController2 中有两个视图控制器。
ViewController2 提供一个操作表。在我的委托中,即视图控制器本身,我关闭了视图控制器。
- (void)actionSheet:(UIActionSheet *)actionSheet didDismissWithButtonIndex:(NSInteger)buttonIndex {
[self.navigationController popViewControllerAnimated:YES];
}
我观察到的是,在 iOS8.1 中,此操作表以某种方式保留了它所呈现的视图。在 iOS 7.1 中,这可以正常工作。
有没有人遇到过这个,或者有任何解决方法?我创建了https://github.com/brightredchilli/iOS8-actionsheet-tests作为概念证明。