UITapGestureRecognizer not working in UIImageView

前端 未结 9 1655
长发绾君心
长发绾君心 2021-01-03 18:16

I had the following code:

UITapGestureRecognizer *showStoryTapRecognizer = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(showNewsStory         


        
9条回答
  •  梦谈多话
    2021-01-03 19:03

    Maybe ... action:@selector(showNewsStory) instead of action:@selector(showNewsStory:) . Please check it . Are there any other UITapGestureRecognizer in this controller ? Try this:

    otherTapRecognizer.cancelsTouchesInView = NO;
    

提交回复
热议问题