话不多说。直接上图。
//存放弹幕的父控件
LinearLayout danmakuContainer = (LinearLayout) view.findViewById(R.id.danmakulayout);
PopDanmu popDanmu = new PopDanmu().init(getActivity(), danmakuContainer, R.layout.item_pop_comment);
popDanmu.setResInterface(new PopDanmu.ResInterface() {
@Override
public void loadImage(View contentView) {
//加载图片
AppUtils.loadImage(true, App.getInstance().currentUser.getMemberAvatar(), (SimpleDraweeView) contentView.findViewById(R.id.iv_head));
}
});
popDanmu.start(danmu);
示例下载地址:点击打开链接