修复首页排行榜闪退问题

This commit is contained in:
zlzw 2022-11-17 17:20:26 +08:00
parent 62ed0ae78e
commit 06d241c66c

View File

@ -86,9 +86,11 @@ public abstract class AbsMainListChildViewHolder extends AbsMainViewHolder imple
mRefreshView.setLayoutManager(new LinearLayoutManager(mContext, LinearLayoutManager.VERTICAL, false));
loadData = list -> {
Log.i("测试", "onData: " + list.size());
hv.setData(list.get(0), 0);
hv.setData(list.get(1), 1);
hv.setData(list.get(2), 2);
for (int i = 0; i < list.size(); i++) {
if (i < 3) {
hv.setData(list.get(i), i);
}
}
};
rootView.addOnOffsetChangedListener(new AppBarLayout.BaseOnOffsetChangedListener() {
@Override