How to cancel touch in all subzones?

Is there an easy way to do this?

+3
source share
2 answers

Override hitTest:withEvent:in UIViewto always return self, and will no longer pass touch events to subviews.

+2
source
someSubview.userInteractionEnabled = NO;
+1
source

Source: https://habr.com/ru/post/1742086/


All Articles