gpt4 book ai didi

ios - presentViewController 隐藏 presentingViewController

转载 作者:行者123 更新时间:2023-11-29 03:23:11 25 4
gpt4 key购买 nike

有没有办法在 iOS 中呈现 ViewController,同时保持呈现的 ViewController 可见?现在,PresentingViewController 似乎在动画完成后就被隐藏了。

最佳答案

使用 UIModalPresentationStyle 中的值来控制它。

UIModalPresentationPageSheetUIModalPresentationFormSheet 将导致在下面留下一定量的 presenting View Controller 的演示文稿。

在正在呈现的 View Controller 上设置modalPresentationStyle

例如

presentedViewController.modalPresentationStyle = UIModalPresentationFormSheet;

[presentingViewController presentViewController:presentedViewController animated:YES completion:nil];

关于ios - presentViewController 隐藏 presentingViewController,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/20815400/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com