Please help me to turn off user interaction.
I have a custom view which appears for several seconds on the top level of view hierarchy. There are several buttons under the view. The problem is that buttons catch touch events when user clicks on view. I’ve set myCustomView.userInteractionEnabled = NO; And nothing happens. Buttons catch events through view all the same. How to create a view which will not allow to intercept touches through it?
Please help me to turn off user interaction. I have a custom view which
Share
If
myCustomViewis at the top level of view hierarchy, I imagine you are trying to implement something like an overlay view, that covers the other views translucently. In this case, settinguserInteractionEnabled = NOon this view will cause touch events to be forwarded to the views below.The correct way is to set
userInteractionEnabled = YESon your custom view, then either create a transparent button to reroute touch to a dismiss IBAction, or ignore it.