Added in API level 21

ChangeImageTransform


open class ChangeImageTransform : Transition
kotlin.Any
   ↳ android.transition.Transition
   ↳ android.transition.ChangeImageTransform

This Transition captures an ImageView's matrix before and after the scene change and animates it during the transition.

In combination with ChangeBounds, ChangeImageTransform allows ImageViews that change size, shape, or android.widget.ImageView.ScaleType to animate contents smoothly.

Summary

Inherited constants
Public constructors

Public methods
open Unit
captureEndValues(transitionValues: TransitionValues!)

open Unit

open Animator?
createAnimator(sceneRoot: ViewGroup, startValues: TransitionValues?, endValues: TransitionValues?)

Creates an Animator for ImageViews moving, changing dimensions, and/or changing android.widget.ImageView.ScaleType.

open Array<String!>!

Inherited functions

Public constructors

ChangeImageTransform

Added in API level 21
ChangeImageTransform()

ChangeImageTransform

Added in API level 21
ChangeImageTransform(
    context: Context!,
    attrs: AttributeSet!)

Public methods

captureEndValues

Added in API level 21
open fun captureEndValues(transitionValues: TransitionValues!): Unit
Parameters
transitionValues TransitionValues!: The holder for any values that the Transition wishes to store. Values are stored in the values field of this TransitionValues object and are keyed from a String value. For example, to store a view's rotation value, a transition might call transitionValues.values.put("appname:transitionname:rotation", view.getRotation()). The target view will already be stored in the transitionValues structure when this method is called.

captureStartValues

Added in API level 21
open fun captureStartValues(transitionValues: TransitionValues!): Unit
Parameters
transitionValues TransitionValues!: The holder for any values that the Transition wishes to store. Values are stored in the values field of this TransitionValues object and are keyed from a String value. For example, to store a view's rotation value, a transition might call transitionValues.values.put("appname:transitionname:rotation", view.getRotation()). The target view will already be stored in the transitionValues structure when this method is called.

createAnimator

Added in API level 21
open fun createAnimator(
    sceneRoot: ViewGroup,
    startValues: TransitionValues?,
    endValues: TransitionValues?
): Animator?

Creates an Animator for ImageViews moving, changing dimensions, and/or changing android.widget.ImageView.ScaleType.

Parameters
sceneRoot ViewGroup: The root of the transition hierarchy. This value cannot be null.
startValues TransitionValues?: The values for a specific target in the start scene. This value may be null.
endValues TransitionValues?: The values for the target in the end scene. This value may be null.
Return
Animator? An Animator to move an ImageView or null if the View is not an ImageView, the Drawable changed, the View is not VISIBLE, or there was no change.

getTransitionProperties

Added in API level 21
open fun getTransitionProperties(): Array<String!>!
Return
Array<String!>! An array of property names as described in the class documentation for TransitionValues. The default implementation returns null.