Commit 2cb26cab authored by Geoffrey Métais's avatar Geoffrey Métais
Browse files

TV Browser: sanity check

(cherry picked from commit eea7551c)
parent 7ccff62d
......@@ -123,8 +123,10 @@ class FileTvItemAdapter(private val type: Long, private val eventsHandler: IEven
val scale = newWidth.toFloat() / itemSize
binding.container.animate().scaleX(scale).scaleY(scale).translationZ(scale)
eventsHandler.onItemFocused(binding.root, getItem(layoutPosition))
focusListener?.onFocusChanged(layoutPosition)
if (layoutPosition in dataset.indices) {
eventsHandler.onItemFocused(binding.root, getItem(layoutPosition))
focusListener?.onFocusChanged(layoutPosition)
}
} else {
binding.container.animate().scaleX(1f).scaleY(1f).translationZ(1f)
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment