aboutsummaryrefslogtreecommitdiff
path: root/adapter/src/main/kotlin/ca/allanwang/kau/iitems/KauIItem.kt
diff options
context:
space:
mode:
authorAllan Wang <me@allanwang.ca>2018-04-07 20:23:17 -0400
committerGitHub <noreply@github.com>2018-04-07 20:23:17 -0400
commita0377be622f21b4c6a7d8828505c1e95efab1254 (patch)
tree825760fab6f0bb1baa4e709443becefba5a8d06a /adapter/src/main/kotlin/ca/allanwang/kau/iitems/KauIItem.kt
parente97db5c6529b1e12effc7141f277bd41d3fb580a (diff)
downloadkau-a0377be622f21b4c6a7d8828505c1e95efab1254.tar.gz
kau-a0377be622f21b4c6a7d8828505c1e95efab1254.tar.bz2
kau-a0377be622f21b4c6a7d8828505c1e95efab1254.zip
Update/android studio 3.1 (#146)
* Update dependencies * Add default invalid id value * Extend appcompat views only * Update migration * Remove setTextIfValid * Remove nosibling warning * Add deprecation warnings to fragment view binding * Bring back glide 4.6.1 * Use proper distribution type setter
Diffstat (limited to 'adapter/src/main/kotlin/ca/allanwang/kau/iitems/KauIItem.kt')
-rw-r--r--adapter/src/main/kotlin/ca/allanwang/kau/iitems/KauIItem.kt2
1 files changed, 2 insertions, 0 deletions
diff --git a/adapter/src/main/kotlin/ca/allanwang/kau/iitems/KauIItem.kt b/adapter/src/main/kotlin/ca/allanwang/kau/iitems/KauIItem.kt
index c01dea4..196959c 100644
--- a/adapter/src/main/kotlin/ca/allanwang/kau/iitems/KauIItem.kt
+++ b/adapter/src/main/kotlin/ca/allanwang/kau/iitems/KauIItem.kt
@@ -1,5 +1,6 @@
package ca.allanwang.kau.iitems
+import android.annotation.SuppressLint
import android.support.annotation.LayoutRes
import android.support.v7.widget.RecyclerView
import android.view.View
@@ -18,6 +19,7 @@ open class KauIItem<Item, VH : RecyclerView.ViewHolder>(
private val viewHolder: (v: View) -> VH,
private val type: Int = layoutRes
) : AbstractItem<Item, VH>() where Item : IItem<*, *>, Item : IClickable<*> {
+ @SuppressLint("ResourceType")
final override fun getType(): Int = type
final override fun getViewHolder(v: View): VH = viewHolder(v)
final override fun getLayoutRes(): Int = layoutRes