Add back drag listeners!

This commit is contained in:
Naveen 2023-09-04 10:02:18 +05:30
parent 87a5ef5278
commit 87d845c137
No known key found for this signature in database
GPG key ID: 0E155DAD31671DA3
3 changed files with 8 additions and 2 deletions

View file

@ -33,6 +33,10 @@ abstract class BaseMusicAdapter<Type>(
val placeholderBig by lazy { resources.getBiggerPlaceholder(textColor) }
open val cornerRadius by lazy { resources.getDimension(com.simplemobiletools.commons.R.dimen.rounded_corner_radius_small).toInt() }
init {
setupDragListener(true)
}
override fun getItemCount() = items.size
override fun getSelectableItemCount() = items.size

View file

@ -24,6 +24,10 @@ class ExcludedFoldersAdapter(
private val config = activity.config
init {
setupDragListener(true)
}
override fun getActionMenuId() = com.simplemobiletools.commons.R.menu.cab_remove_only
override fun prepareActionMode(menu: Menu) {}

View file

@ -42,8 +42,6 @@ class TracksAdapter(
private var startReorderDragListener: StartReorderDragListener
init {
setupDragListener(true)
touchHelper = ItemTouchHelper(ItemMoveCallback(this))
touchHelper!!.attachToRecyclerView(recyclerView)