84669 person learning
152542 person learning
20005 person learning
5487 person learning
7821 person learning
359900 person learning
3350 person learning
180660 person learning
48569 person learning
18603 person learning
40936 person learning
1549 person learning
1183 person learning
32909 person learning
在 Cell 中有一个播放语音的图片,点击之后用uiimage通过animationImages播放几张图片,但是当 Cell 滚出屏幕之外的时候,uiimage就不动了,不知是复用覆盖了还是怎么?求大神给个解决思路啊
小伙看你根骨奇佳,潜力无限,来学PHP伐。
终于知道了,我是这样做的,
在聊天 VC 中收到后播放音频文件,并缓存cell.rowIdentifier给_rowPlayVoiceAnimationIdentifier,然后遍历visibleCells,如果 Cell 标识(row) 和缓存的一样,则调用 Cell playVoiceAnimation方法 音频播放结束后调用,同上,调用 Cell stopVoiceAnimation方法
滚动时处理: //cell 将要显示出来的时候,如果是正在播放录音文件的 Cell,那么执行Cell播放录音动画 if (((ACChatTableViewCell *)cell).rowIdentifier == _rowPlayVoiceAnimationIdentifier) { [((ACChatTableViewCell *)cell) startVoiceAnimation]; }
有点乱!!!
有没有demo提供参考632582467@qq.com
终于知道了,我是这样做的,
上面2个方法写在 cell 里,用于开始、停止图片动画,Cell 有一个标记,点击语音的时候用 block 传回 Cell 标识(rowIdentifier,创建 Cell 时,cell.rowIdentifier = indexPath.row;)和音频文件路径给聊天 VC
在聊天 VC 中收到后播放音频文件,并缓存cell.rowIdentifier给_rowPlayVoiceAnimationIdentifier,然后遍历visibleCells,如果 Cell 标识(row) 和缓存的一样,则调用 Cell playVoiceAnimation方法
音频播放结束后调用,同上,调用 Cell stopVoiceAnimation方法
滚动时处理:
//cell 将要显示出来的时候,如果是正在播放录音文件的 Cell,那么执行Cell播放录音动画
if (((ACChatTableViewCell *)cell).rowIdentifier == _rowPlayVoiceAnimationIdentifier) {
[((ACChatTableViewCell *)cell) startVoiceAnimation];
}
有点乱!!!
有没有demo提供参考
632582467@qq.com