UINavigationController within ViewController, gap at top of view

后端 未结 11 1010
不知归路
不知归路 2021-02-04 03:24

I\'m working on a universal app, and I\'m trying to share as much code as possible between the iPhone and iPad versions. I need to use a TabBarController as my root view contro

11条回答
  •  南方客
    南方客 (楼主)
    2021-02-04 03:40

    I solved this in my app by hiding then showing the navigation bar after adding the navigation controllers view. eg.

    [parentView addSubview:navController.view];
    [navController setNavigationBarHidden:YES];
    [navController setNavigationBarHidden:NO];
    

提交回复
热议问题