【发布时间】:2011-04-20 09:57:11
【问题描述】:
我有一个 UIViewController,它有一个模式窗口,我想在整个界面上呈现它,包括 UITabBar。
我的应用层次结构是这样的:
UITabBarController (A) ->
UIViewController (B) ->
UINavigationController (C) ->
UIViewController (D) ->
UIViewController (my modal view)
当我在 D 上调用 presentModalViewController 时,模态视图显示在 UITabBar 下方,或者应该说,UITabBar 仍然显示。
我尝试在模态视图控制器上将hidesBottomBarWhenPushed 属性设置为YES,但无济于事。
关于为什么这对我不起作用的任何想法?
【问题讨论】:
-
我从来没有遇到过这个问题。我所有的模态都显示在标签栏上。我认为这将是您的控制器层次结构。通常是UITabBarController->UINavigationController->UIViewController。如果您没有充分的理由这样做,我认为您必须删除 (B)。
标签: uiviewcontroller ios uitabbarcontroller