Touches Ended not being called

前端 未结 7 1077
無奈伤痛
無奈伤痛 2021-01-17 09:53

I\'ve playing around with recognizing the touches in an iOS Application, and I have this simple code

- (void)touchesBegan:(NSSet *)touches withEvent:(UIEvent         


        
相关标签:
7条回答
  • 2021-01-17 10:37

    I had the same problem, even after defining all four touch handlers. I also didn't have any active recognizers.

    The solution for me was to simply enable multi touch events on my view, like so

    self.multipleTouchEnabled = YES;
    

    which magically solved the problem.

    Note that I did get "multi touch" events even before this, i.e. events for multiple fingers at the same time, but I had the above issue that not all of them were ended properly.

    Hope that helps someone! :)

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