我正在尝试从下面有tabBar的viewcontroller推送到UserProfileViewController
期间隐藏标签栏。
代码:
func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
guard let toVC = UIStoryboard(name:"UserProfile", bundle:nil).instantiateViewController(withIdentifier: "userProfileVC") as? ProfileViewController else { return }
...
toVC.hidesBottomBarWhenPushed = true
self.navigationController?.pushViewController(toVC, animated: true)
}
所以代码工作正常,它确实隐藏了推送时的底栏。然而,在推动之后,它给了我一点延迟,并在下面显示一个空白的空白区域,因为隐藏的标签栏就像一两秒钟。我想在推动时摆脱底部的白色空间。请帮忙。
我已经尝试过了:
Hide Bottom Bar On Push
Under Opaque Bars On Push
布局&在故事板中勾选的扩展边缘选项: