How to change a UIBarButtonItem in a UINavigationBar

前端 未结 5 1734
醉酒成梦
醉酒成梦 2021-02-06 04:40

I\'m trying to set up a list of items that can be edited. I have a main view, with a UINavigationBar at the top and a UITableView directly under it. I\'d like to have my \"edit\

5条回答
  •  南方客
    南方客 (楼主)
    2021-02-06 05:14

    you can try it

    [self setValue:viewController.navigationItem forKey:@"_navigationItem"];
    [self.navigationController setNavigationBarHidden:YES animated:NO];
    [self.navigationController setNavigationBarHidden:NO animated:NO];
    

提交回复
热议问题