Customize the More UIBarButtonItem in UITabBar

后端 未结 1 1241
说谎
说谎 2020-12-10 23:18

Since iOS 5 Apple provided an API to customise the UITabBarItems in the UITabBar object. I am refering specifically to the following selector:

相关标签:
1条回答
  • 2020-12-11 00:07

    The solution was silly.

    I assumed the UITabBarItems in the moreNavigationController was readonly and it wasn't. So simply doing the following:

    tabBarController.moreNavigationController.tabBarItem = [[UITabBarItem alloc] initWithTitle:@"More" image:[UIImage imageNamed:@"BarIcon-More.png"] tag:0];
    

    And the same customization code as above works.

    0 讨论(0)
提交回复
热议问题