feat: 优化代码

pull/103/head
kunfei 5 years ago
parent c7c5b15cd1
commit 71c228322f
  1. 9
      app/src/main/java/io/legado/app/base/adapter/CommonRecyclerAdapter.kt

@ -19,13 +19,14 @@ import java.util.*
abstract class CommonRecyclerAdapter<ITEM>(protected val context: Context) :
RecyclerView.Adapter<ItemViewHolder>() {
constructor(context: Context, vararg delegates: Pair<Int, ItemViewDelegate<ITEM>>) : this(
context
) {
constructor(context: Context, vararg delegates: ItemViewDelegate<ITEM>) : this(context) {
addItemViewDelegates(*delegates)
}
constructor(context: Context, vararg delegates: ItemViewDelegate<ITEM>) : this(context) {
constructor(
context: Context,
vararg delegates: Pair<Int, ItemViewDelegate<ITEM>>
) : this(context) {
addItemViewDelegates(*delegates)
}

Loading…
Cancel
Save