Dan*_*iel 5 ios uialertcontroller
UIAlertController我这样称呼:
UIAlertController *alertController = [UIAlertController alertControllerWithTitle:@"title"
message:@"msg"
preferredStyle:UIAlertControllerStyleAlert];
UIAlertAction *okAction = [UIAlertAction actionWithTitle:@"Accept"
style:UIAlertActionStyleDefault
handler:^(UIAlertAction *action) {/*...*/}
UIAlertAction *cancelAction = [UIAlertAction actionWithTitle:@"Cancel"
style:UIAlertActionStyleCancel
handler:^(UIAlertAction *action) {/*...*/}];
[alertController addAction:cancelAction];
[alertController addAction:okAction];
[self presentViewController:alertController animated:YES completion:nil];
Run Code Online (Sandbox Code Playgroud)
我的问题是,当UIAlertController显示时,它会将导航栏的颜色从黄色更改为白色,并将系统的灯光信息按钮从蓝色更改为灰色(它看起来没有错,它看起来像是想要的“让屏幕看起来色彩较少”效果)。如果用户当时按下主页按钮,当应用程序再次从后台进入时,应用程序将保持该颜色(这会将用户带到具有白色/灰色的登录屏幕)。
这个问题有解决方法吗?
| 归档时间: |
|
| 查看次数: |
1316 次 |
| 最近记录: |