DefaultItemAnimator

(SESL variant) This implementation of RecyclerView.ItemAnimator provides basic animations on remove, add, and move events that happen to the items in a RecyclerView. RecyclerView uses a DefaultItemAnimator by default.

See also

Constructors

Link copied to clipboard
constructor()

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Functions

Link copied to clipboard
Called when an item is added to the RecyclerView.
Link copied to clipboard
open fun animateChange(oldHolder: RecyclerView.ViewHolder, newHolder: RecyclerView.ViewHolder, fromLeft: Int, fromTop: Int, toLeft: Int, toTop: Int): Boolean
Called when an item is changed in the RecyclerView, as indicated by a call to RecyclerView.Adapter#notifyItemChanged(int) or RecyclerView.Adapter#notifyItemRangeChanged(int, int).
Link copied to clipboard
open fun animateMove(holder: RecyclerView.ViewHolder, fromX: Int, fromY: Int, toX: Int, toY: Int): Boolean
Called when an item is moved in the RecyclerView.
Link copied to clipboard
Called when an item is removed from the RecyclerView.
Link copied to clipboard
When an item is changed, ItemAnimator can decide whether it wants to re-use the same ViewHolder for animations or RecyclerView should create a copy of the item and ItemAnimator will use both to run the animation (e.g.
Link copied to clipboard
Link copied to clipboard
open fun enableRemoveDelay(enable: Boolean)
Link copied to clipboard
Method called when an animation on a view should be ended immediately.
Link copied to clipboard
open fun endAnimations()
Method called when all item animations should be ended immediately.
Link copied to clipboard
open fun getAddDuration(): Long
Gets the current duration for which all add animations will run.
Link copied to clipboard
Gets the current duration for which all change animations will run.
Link copied to clipboard
Link copied to clipboard
open fun getMoveDuration(): Long
Gets the current duration for which all move animations will run.
Link copied to clipboard
Link copied to clipboard
Gets the current duration for which all remove animations will run.
Link copied to clipboard
Link copied to clipboard
open fun isRunning(): Boolean
Method which returns whether there are any item animations currently running.
Link copied to clipboard
Called when there are pending animations waiting to be started.