|
|
@ -74,9 +74,11 @@ class ChangeBookSourceAdapter( |
|
|
|
override fun registerListener(holder: ItemViewHolder, binding: ItemChangeSourceBinding) { |
|
|
|
override fun registerListener(holder: ItemViewHolder, binding: ItemChangeSourceBinding) { |
|
|
|
holder.itemView.setOnClickListener { |
|
|
|
holder.itemView.setOnClickListener { |
|
|
|
getItem(holder.layoutPosition)?.let { |
|
|
|
getItem(holder.layoutPosition)?.let { |
|
|
|
|
|
|
|
if (it.bookUrl != callBack.bookUrl) { |
|
|
|
callBack.changeTo(it) |
|
|
|
callBack.changeTo(it) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
holder.itemView.onLongClick { |
|
|
|
holder.itemView.onLongClick { |
|
|
|
showMenu(holder.itemView, getItem(holder.layoutPosition)) |
|
|
|
showMenu(holder.itemView, getItem(holder.layoutPosition)) |
|
|
|
} |
|
|
|
} |
|
|
|