TransitionAdapter
public
abstract
class
TransitionAdapter
extends Object
implements
MotionLayout.TransitionListener
java.lang.Object
|
↳ |
android.support.constraint.motion.TransitionAdapter
|
Summary
Inherited methods |
From class
java.lang.Object
Object
|
clone()
|
boolean
|
equals(Object arg0)
|
void
|
finalize()
|
final
Class<?>
|
getClass()
|
int
|
hashCode()
|
final
void
|
notify()
|
final
void
|
notifyAll()
|
String
|
toString()
|
final
void
|
wait(long arg0, int arg1)
|
final
void
|
wait(long arg0)
|
final
void
|
wait()
|
|
From interface
android.support.constraint.motion.MotionLayout.TransitionListener
|
Public constructors
TransitionAdapter
public TransitionAdapter ()
Public methods
onTransitionChange
public void onTransitionChange (MotionLayout motionLayout,
int startId,
int endId,
float progress)
Called when a drawer's position changes.
Parameters |
motionLayout |
MotionLayout : The TransitionLayout view that was moved |
startId |
int : the id of the start state (or ConstraintSet). Will be -1 if unknown. |
endId |
int : the id of the end state (or ConstraintSet). |
progress |
float : The progress on this transition, from 0 to 1.
|
onTransitionCompleted
public void onTransitionCompleted (MotionLayout motionLayout,
int currentId)
Called when a drawer has settled completely a state.
The TransitionLayout is interactive at this point.
Parameters |
motionLayout |
MotionLayout : Drawer view that is now open |
currentId |
int : the id it has reached
|
onTransitionStarted
public void onTransitionStarted (MotionLayout motionLayout,
int startId,
int endId)
Called when a drawer is about to start a transition.
Note. startId may be -1 if starting from an "undefined state"
Parameters |
motionLayout |
MotionLayout : The TransitionLayout view that was moved |
startId |
int : the id of the start state (or ConstraintSet). Will be -1 if unknown. |
endId |
int : the id of the end state (or ConstraintSet).
|
onTransitionTrigger
public void onTransitionTrigger (MotionLayout motionLayout,
int triggerId,
boolean positive,
float progress)
Call when a trigger is fired
Parameters |
triggerId |
int : The id set set with triggerID |
positive |
boolean : for positive transition edge |
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2025-02-10 UTC.
[null,null,["Last updated 2025-02-10 UTC."],[],[]]