Update support library and kotlin

This commit is contained in:
inorichi
2017-11-28 00:21:38 +01:00
parent 4a9151e4aa
commit 604929d002
14 changed files with 29 additions and 31 deletions
@@ -79,7 +79,7 @@ class LibraryAdapter(private val controller: LibraryController) : RecyclerViewPa
/**
* Returns the position of the view.
*/
override fun getItemPosition(obj: Any?): Int {
override fun getItemPosition(obj: Any): Int {
val view = obj as? LibraryCategoryView ?: return POSITION_NONE
val index = categories.indexOfFirst { it.id == view.category.id }
return if (index == -1) POSITION_NONE else index