<Transition>

Specifies the beginning and end state of a motion sequence, the target intermediate states, and the user interactions that trigger the motion.

Syntax

<Transition
  motion:constraintSetStart="start"
  motion:constraintSetEnd="end"
  [ motion:duration="integer" ] >
  ...
</Transition>

Attributes

motion:constraintSetStart
Initial state of the motion sequence. This can either be the ID of a <ConstraintSet> or a layout. To specify a <ConstraintSet>, set this attribute to "@+id/constraintSetId". To specify a layout, set it to "@layout/layoutState".
motion:constraintSetEnd
Final state of the motion sequence. This can either be the ID of a <ConstraintSet>, or a layout. To specify a <ConstraintSet>, set this attribute to "@+id/constraintSetId". To specify a layout, set it to "@layout/layoutState".
motion:duration
Duration of the motion sequence in milliseconds. If not specified, the <MotionScene> element's defaultDuration is used.

Can contain

<onClick>
Indicates that the motion sequence is triggered by a user touch.
<onSwipe>
Indicates that the motion sequence is triggered by a user swipe.
<KeyFrameSet>
Specifies one or more intermediate positions or attribute settings for elements in the motion sequence.

Contained in