Revert "Glimpse: ThumbnailLayoutManager: Ignore OOB in onLayoutChildren"

Not needed anymore, we don't insert items onLayout.

This reverts commit ad1c6996f5.

Change-Id: Icc482e8f97229c05490786282e00e33da4ad441f
This commit is contained in:
Luca Stefani 2023-08-07 09:52:33 +02:00 committed by Sebastiano Barezzi
parent 336a869299
commit dc0aa894df
1 changed files with 0 additions and 8 deletions

View File

@ -7,7 +7,6 @@ package org.lineageos.glimpse.thumbnail
import android.content.Context
import androidx.recyclerview.widget.GridLayoutManager
import androidx.recyclerview.widget.RecyclerView
import org.lineageos.glimpse.ext.px
class ThumbnailLayoutManager(
@ -18,13 +17,6 @@ class ThumbnailLayoutManager(
spanSizeLookup = ThumbnailSpanSizeLookup(adapter, spanCount)
}
override fun onLayoutChildren(recycler: RecyclerView.Recycler?, state: RecyclerView.State?) {
try {
super.onLayoutChildren(recycler, state)
} catch (_: IndexOutOfBoundsException) {
}
}
private class ThumbnailSpanSizeLookup(
private val adapter: ThumbnailAdapter,
private val spanCount: Int,