GridBaseAdapter

class GridBaseAdapter(context: GalleryFragment) : BaseAdapter

A BaseAdapter used by GalleryFragment to inflate Views of previously taken screenshot pairs (cropped,full).

Parameters

context

Instance of GalleryFragment, in which the inflated views will be used

Constructors

GridBaseAdapter
Link copied to clipboard
fun GridBaseAdapter(context: GalleryFragment)

Functions

clear
Link copied to clipboard
fun clear()
getCount
Link copied to clipboard
open override fun getCount(): Int

Returns the total count of image pairs in imagePairs.

getItem
Link copied to clipboard
open override fun getItem(position: Int): Any

Returns an image pair stored in imagePairs at the specified position.

getItemId
Link copied to clipboard
open override fun getItemId(position: Int): Long

Returns the ID of an item at the specified position.

getView
Link copied to clipboard
open override fun getView(position: Int, convertView: View?, parent: ViewGroup?): View

Returns an inflated View for an image pair.

Properties

context
Link copied to clipboard
private val context: GalleryFragment
gfvm
Link copied to clipboard
private var gfvm: GalleryViewModel?

GalleryViewModel, supplies and updates imagePairs with image pairs

imagePairs
Link copied to clipboard
private var imagePairs: ArrayList<ArrayList<File>>

Local variable that stores all image pairs that will be displayed in the gallery