Is there a way to detect touches when the gesture started outside of the current view?
开发者_JS百科Example:
I have a small view where I detect touches. User starte moving finger on screen, starting outside of by view and then enters it without lifting finger. When finger enters view, the view does not get any touch events.Override pointInside:withEvent:
in your view and that should do it, though the point has to be within the parent view and the child view has to be visible and have user interaction enabled.
I remember a method that you can add a custom transparent UIButton, which cover all screen. And any touch outside of another view will trigger this UIButton event.
精彩评论