去除 UINavigationController 的黑色背景

remove black background of UINavigationController

我一直在 UINavigationController 的根 ViewController 上添加滑动以关闭,它有效,但是当您平移视图时,它后面有一个黑色背景。 UINavigationController 以模态方式显示在另一个视图上,我想在用户平移时显示下方的视图,但我找不到更改黑色背景或它在 UINavigationController 上设置的位置的方法。有谁知道我该如何改变它?

谢谢...

我通过更改

设法使它工作
navController.modalPresentationStyle = UIModalPresentationStyle.fullScreen

navController.modalPresentationStyle = UIModalPresentationStyle.overCurrentContext