tableviewcell上使用YYlabel,添加高亮点击事件,点击事件不响应
首先很感谢您的这份开源库。功能很强大。使用的时候遇到了一个问题,希望您可以给解答一下。在tableview用YYLabel做了富文本处理和高亮点击事件,同时也在tableView上加了tap手势。点击YYLabel的时候,触发了tableview的点击事件,高亮点击没有作用,有什么解决方案嘛? 大大。将tableview的点击事件注释之后,YYLabel的高亮点击事件还是没有触发。求正确的食用方法。大大。 代码如下: if (modelSource.attMessage) { self.Binfo.attributedText = modelSource.attMessage; self.Binfo.textLayout = modelSource.textLayout; self.Binfo.size = modelSource.textLayout.textBoundingSize; } WS(weakSelf); [modelSource.attMessage yy_setTextHighlightRange:modelSource.receiveRange color:nil backgroundColor:nil tapAction:^(UIView * _Nonnull containerView, NSAttributedString * _Nonnull text, NSRange range, CGRect rect) { // [weakSelf receiverMessagePrivate:modelSource]; NSLog(@"kkkkkskk%@",text); }];
请问你这个解决了吗?
我是覆盖了一层手势在tableView上,导致此问题,已解决
我也遇见过 不知道有撒好的方法可以解决的
你肯定是在他上面一层view上加了其他手势
http://events.jianshu.io/p/4ac26c5f887a
上层view也没加手势啊