Add a UIButton as a subview to a UITabBar

后端 未结 2 1812
别那么骄傲
别那么骄傲 2020-12-11 16:42

I am trying to implement a hideable UITabBar in my app. I\'ve set up all the animations, and they work very well. I\'m just having an issue getting my UIButton \"pull-tab\"

相关标签:
2条回答
  • 2020-12-11 17:02

    Since you have the hiding part working within the UITabbar and from the answer i have seen here, one alternative would be to keep the UIButton within the UITabbar but also add the button to the view when the UITabbar is hidden (so you will have two button that overlay). When the tabbar is displayed hide the button you have added to the view using the hidden property on the view.

    0 讨论(0)
  • 2020-12-11 17:16

    You can still add the UIButton to the UITabBarController's main view, not in the UITabBar though.... [myUITabBarController.view addSubview:pullButton]

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