use of se.zinokader.spotiq.util.view.CustomDividerItemDecoration in project SpotiQ by ZinoKader.
the class PartyMemberFragment method onCreateView.
@Nullable
@Override
public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
binding = DataBindingUtil.inflate(inflater, R.layout.fragment_party_members, container, false);
partyMemberRecyclerAdapter = new PartyMemberRecyclerAdapter(partyMembers);
binding.membersRecyclerView.setLayoutManager(new LinearLayoutManager(getContext()));
binding.membersRecyclerView.addItemDecoration(new CustomDividerItemDecoration(getContext().getDrawable(R.drawable.search_list_divider), false, false));
AlphaInAnimationAdapter animatedAdapter = new AlphaInAnimationAdapter(partyMemberRecyclerAdapter);
animatedAdapter.setInterpolator(new AccelerateDecelerateInterpolator());
animatedAdapter.setHasStableIds(true);
animatedAdapter.setStartPosition(ApplicationConstants.DEFAULT_LIST_ANIMATION_ITEM_POSITION_START);
animatedAdapter.setDuration(ApplicationConstants.DEFAULT_LIST_ANIMATION_DURATION_MS);
binding.membersRecyclerView.setAdapter(animatedAdapter);
return binding.getRoot();
}
use of se.zinokader.spotiq.util.view.CustomDividerItemDecoration in project SpotiQ by ZinoKader.
the class TracklistFragment method onCreateView.
@Override
public View onCreateView(LayoutInflater inflater, ViewGroup parentContainer, Bundle savedInstanceState) {
binding = DataBindingUtil.inflate(inflater, R.layout.fragment_tracklist, parentContainer, false);
binding.tracklistRecyclerView.setLayoutManager(new LinearLayoutManager(inflater.getContext()));
binding.tracklistRecyclerView.setEmptyView(binding.tracklistEmptyView);
binding.tracklistRecyclerView.setItemAnimator(itemAnimator);
binding.tracklistRecyclerView.addItemDecoration(new CustomDividerItemDecoration(getResources().getDrawable(R.drawable.track_list_padding_divider), true, true));
binding.tracklistRecyclerView.setAdapter(new TracklistRecyclerAdapter(songs));
return binding.getRoot();
}
Aggregations