Swipe Dismiss Behavior
An interaction behavior plugin for child views of CoordinatorLayout to provide support for the 'swipe-to-dismiss' gesture.
Inheritors
Types
Link copied to clipboard
interface OnDismissListener
Callback interface used to notify the application that the view has been dismissed.
Properties
Link copied to clipboard
Link copied to clipboard
A view is currently being dragged.
Link copied to clipboard
A view is not currently being dragged or animating as a result of a fling/snap.
Link copied to clipboard
A view is currently settling into place as a result of a fling or predefined non-interactive motion.
Link copied to clipboard
Swipe direction which allows swiping in either direction.
Link copied to clipboard
Swipe direction that only allows swiping in the direction of end-to-start.
Link copied to clipboard
Swipe direction that only allows swiping in the direction of start-to-end.
Functions
Link copied to clipboard
Called when the user's input indicates that they want to swipe the given view.
Link copied to clipboard
Retrieve the current drag state of this behavior.
Link copied to clipboard
open fun onInterceptTouchEvent(@NonNull parent: CoordinatorLayout, @NonNull child: V, @NonNull event: MotionEvent): Boolean
Link copied to clipboard
open fun onLayoutChild(@NonNull parent: CoordinatorLayout, @NonNull child: V, layoutDirection: Int): Boolean
Link copied to clipboard
Link copied to clipboard
Set the threshold for telling if a view has been dragged enough to be dismissed.
Link copied to clipboard
The maximum swipe distance for the view's alpha is modified.
Link copied to clipboard
Set the sensitivity used for detecting the start of a swipe.
Link copied to clipboard
The minimum swipe distance before the view's alpha is modified.
Link copied to clipboard
Sets the swipe direction for this behavior.