Skip to content

Commit

Permalink
Update: updated the version.
Browse files Browse the repository at this point in the history
  • Loading branch information
pokk committed Jan 8, 2019
1 parent 7a9751e commit 97fffd6
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@ Create a multiple view type factory for providing difference view type and view
```kotlin
class MultiTypeFactory: ViewTypeFactory() {
override var transformMap: MutableMap<Int, Pair<Int, (View) -> ViewHolder>> =
mutableMapOf(1 to Pair(R.layout.item_first, { itemView -> FirstViewHolder(itemView) }),
2 to Pair(R.layout.item_second, { itemView -> SecondViewHolder(itemView) }))
mutableMapOf(1 to Pair(R.layout.item_first ) { itemView -> FirstViewHolder(itemView) },
2 to Pair(R.layout.item_second ) { itemView -> SecondViewHolder(itemView) })

fun type(typeone: ProductTypeOne): Int = 1

Expand Down Expand Up @@ -105,7 +105,7 @@ please. There is a simple sample for this library. 😄
It's very easy to import, you just put them into your gradle file.

```gradle
compile "com.devrapid.jieyi:adaptiverecyclerview:1.0.5"
compile "com.devrapid.jieyi:adaptiverecyclerview:1.0.6"
```

## Maven
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ package com.devrapid.adaptiverecyclerview
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import androidx.recyclerview.widget.DiffUtil
import androidx.recyclerview.widget.RecyclerView

/**
* An adaptive [RecyclerView] which accepts multiple type layout.
Expand Down Expand Up @@ -66,7 +68,7 @@ abstract class AdaptiveAdapter<VT : ViewTypeFactory, M : IVisitable<VT>, VH : Re
val itemView: View =
LayoutInflater.from(parent.context).inflate(typeFactory.getLayoutResource(viewType), parent, false)

return typeFactory.createViewHolder(viewType, itemView)
return typeFactory.createViewHolder(viewType, itemView) as VH
}
//endregion

Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ proj_name=adaptiverecyclerview
proj_libname=AdaptiveRecyclerview
proj_group=com.devrapid.jieyi
proj_artifactid=adaptiverecyclerview
proj_version=1.0.5
proj_version=1.0.6
proj_description=Create an adaptive recycler view for each of type view.
proj_websiteurl=https://github.com/pokk/AdaptiveRecyclerView
proj_issuetrackerurl=https://github.com/pokk/AdaptiveRecyclerView/issues
Expand Down

0 comments on commit 97fffd6

Please sign in to comment.