我正在尝试打开电子邮件视图控制器 ( MFMailComposeViewController
),并且我阅读的所有内容都建议使用presentModalViewController:animated:
,这似乎需要发送到UIViewController
.
例如,在文档中,它说:
调用
presentModalViewController:animated:
当前视图控制器的方法,传入你想要模态呈现的视图控制器。
但我没有“当前视图控制器”!我的应用程序完全是 OpenGL,我的设置代码如下所示:
self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
self.view = [[IPhoneView alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
[window addSubview: self.view];
[window makeKeyAndVisible];
IPhoneView
我在课堂上设置了 OpenGL 上下文。
我发现了许多问题,询问如何UIViewController
从 a 中获取 a UIView
,并且共识似乎是:不要。那么如何使用漂亮的滑动动画打开电子邮件视图控制器呢?