use of com.example.jingbin.cloudreader.adapter.FilmAdapter in project CloudReader by youlookwhat.
the class FilmShowingFragment method initRefreshView.
private void initRefreshView() {
viewModel.bookType.set(mType);
bindingView.srlWan.setColorSchemeColors(CommonUtils.getColor(activity, R.color.colorTheme));
adapter = new FilmAdapter(activity);
bindingView.xrvWan.setLayoutManager(new LinearLayoutManager(activity));
bindingView.xrvWan.setItemAnimator(null);
bindingView.xrvWan.setHasFixedSize(true);
bindingView.xrvWan.setLoadMoreEnabled(true);
bindingView.xrvWan.setAdapter(adapter);
bindingView.xrvWan.setOnItemClickListener(new OnItemFilterClickListener() {
@Override
public void onSingleClick(View v, int position) {
ImageView imageView = v.findViewById(R.id.iv_one_photo);
FilmItemBean itemData = adapter.getItemData(position);
FilmDetailActivity.start(activity, itemData, imageView);
}
});
bindingView.srlWan.setOnRefreshListener(this::getHotFilm);
}
Aggregations