显示ABPeoplePickerNavigationController时隐藏标签栏?

时间:2009-08-11 19:10:26

标签: objective-c iphone

我有以下代码来设置并切换到ABPeoplePickerNavigationController。

    ABPeoplePickerNavigationController *peoplePicker = [
        [ABPeoplePickerNavigationController alloc] init
    ];
    peoplePicker.peoplePickerDelegate = self;

    window = [[[currentView superview] superview] superview];       
    [window addSubview:[peoplePicker view]];
    [[[peoplePicker view] layer] addAnimation:animation forKey:@"nav"];

它正在切换的视图由UITabBarController控制。当peoplePicker是活动视图时,我会阻止显示标签栏,但到目前为止我还没有运气。我已经调查了hidesBottomBarWhenPushed,但由于我无法推送导航控制器,所以没有用。我还能做什么?

1 个答案:

答案 0 :(得分:1)

尝试拨打

- (void)presentModalViewController:(UIViewController *)modalViewController animated:(BOOL)animated

UITabBarController对象上。这应该导致ABPeoplePickerNavigationController填满整个窗口,隐藏TabBar。