DropHelper.Options
class DropHelper.Options
Options for configuring drop targets specified by DropHelper.
Summary
Nested types |
|---|
|
Builder for constructing a |
Public functions |
|
|---|---|
@ColorInt Int |
Returns the color used to highlight the drop target. |
Int |
Returns the corner radius of the drop target highlighting. |
(Mutable)List<EditText!> |
Returns a list of the |
Boolean |
Indicates whether or not a drop target highlight color has been set. |
Boolean |
Indicates whether or not a corner radius has been set for the drop target highlighting. |
Boolean |
Indicates whether or not the app should respond to drag events when the drag operation contains |
Public functions
getHighlightColor
fun getHighlightColor(): @ColorInt Int
Returns the color used to highlight the drop target.
| See also | |
|---|---|
hasHighlightColor |
getHighlightCornerRadiusPx
fun getHighlightCornerRadiusPx(): Int
Returns the corner radius of the drop target highlighting.
| Returns | |
|---|---|
Int |
The drop target highlighting corner radius. |
| See also | |
|---|---|
hasHighlightCornerRadiusPx |
getInnerEditTexts
fun getInnerEditTexts(): (Mutable)List<EditText!>
Returns a list of the EditText elements contained in the drop target view hierarchy. A list of EditText elements is supplied when building this DropHelper.Options instance (see addInnerEditTexts).
hasHighlightColor
fun hasHighlightColor(): Boolean
Indicates whether or not a drop target highlight color has been set. If not, a default is used.
| Returns | |
|---|---|
Boolean |
True if a highlight color has been set, false otherwise. |
hasHighlightCornerRadiusPx
fun hasHighlightCornerRadiusPx(): Boolean
Indicates whether or not a corner radius has been set for the drop target highlighting. If not, a default is used.
| Returns | |
|---|---|
Boolean |
True if a corner radius has been set, false otherwise. |
shouldAcceptDragsWithLocalState
fun shouldAcceptDragsWithLocalState(): Boolean
Indicates whether or not the app should respond to drag events when the drag operation contains local state. By default, the app does not respond to drag events that have local state. Setting local state is only possible when the drag operation originated from this activity.
| Returns | |
|---|---|
Boolean |
True if drag events will be accepted when the local state is non-null, otherwise false. |