Question

I'm building an iOS app with an Instagram style center tab (the ones that are raised from the tab bar).

I have my custom view added as a subview to the tabBar, with it's Y value set to -27.0.

The problem I'm having is that only the bottom half of my view receives touches. I've read this question:

UIView. Why Does A Subviews Outside its Parent's Extent Not Receive Touches?

I think this will solve my problem, but I'm a little confused as to where each method goes. Will I need to subclass UITabBarController?

Was it helpful?

Solution

To answer your question, yes I believe you'll need to create a custom subclass of UITabBar and implement the hitTest and pointInside methods as advised in the answer you linked to.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top