allow interpreting grid decoration as string
This commit is contained in:
parent
b8e63ae74e
commit
ff4bca1251
|
@ -7,7 +7,10 @@ import com.simplemobiletools.gallery.pro.models.Medium
|
|||
import com.simplemobiletools.gallery.pro.models.ThumbnailItem
|
||||
|
||||
class GridSpacingItemDecoration(val spanCount: Int, val spacing: Int, val isScrollingHorizontally: Boolean, val addSideSpacing: Boolean,
|
||||
val items: ArrayList<ThumbnailItem>, val useGridPosition: Boolean) : RecyclerView.ItemDecoration() {
|
||||
var items: ArrayList<ThumbnailItem>, val useGridPosition: Boolean) : RecyclerView.ItemDecoration() {
|
||||
|
||||
override fun toString() = "spanCount: $spanCount, spacing: $spacing, isScrollingHorizontally: $isScrollingHorizontally, addSideSpacing: $addSideSpacing, " +
|
||||
"items: ${items.hashCode()}, useGridPosition: $useGridPosition"
|
||||
|
||||
override fun getItemOffsets(outRect: Rect, view: View, parent: RecyclerView, state: RecyclerView.State) {
|
||||
val position = parent.getChildAdapterPosition(view)
|
||||
|
|
Loading…
Reference in New Issue