public static int getSectionItemViewTypeForAdapterViewType(final int itemViewType) {
return itemViewType % VIEW_TYPE_QTY;
}
This is especially useful in the following use case (Drag and move)
@Override
public int getMovementFlags(RecyclerView recyclerView, RecyclerView.ViewHolder viewHolder) {
if (SectionedRecyclerViewAdapter.VIEW_TYPE_ITEM_LOADED != SectionedRecyclerViewAdapter.getSectionItemViewTypeForAdapterViewType(viewHolder.getItemViewType())) {
final int dragFlags = 0;
final int swipeFlags = 0;
return makeMovementFlags(dragFlags, swipeFlags);
}
Can we have https://github.com/luizgrp/SectionedRecyclerViewAdapter/blob/master/library/src/main/java/io/github/luizgrp/sectionedrecyclerviewadapter/SectionedRecyclerViewAdapter.java#L500
as static method?
This is especially useful in the following use case (Drag and move)
Thanks.