public final class

DropHelper.Options

extends java.lang.Object

 java.lang.Object

↳androidx.draganddrop.DropHelper.Options

Overview

Options for configuring drop targets specified by DropHelper.

Summary

Methods
public intgetHighlightColor()

Returns the color used to highlight the drop target.

public intgetHighlightCornerRadiusPx()

Returns the corner radius of the drop target highlighting.

public java.util.List<EditText>getInnerEditTexts()

Returns a list of the elements contained in the drop target view hierarchy.

public booleanhasHighlightColor()

Indicates whether or not a drop target highlight color has been set.

public booleanhasHighlightCornerRadiusPx()

Indicates whether or not a corner radius has been set for the drop target highlighting.

public booleanshouldAcceptDragsWithLocalState()

Indicates whether or not the app should respond to drag events when the drag operation contains .

from java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Methods

public int getHighlightColor()

Returns the color used to highlight the drop target.

Returns:

The drop target highlight color.

See also: DropHelper.Options.hasHighlightColor()

public boolean hasHighlightColor()

Indicates whether or not a drop target highlight color has been set. If not, a default is used.

Returns:

True if a highlight color has been set, false otherwise.

public int getHighlightCornerRadiusPx()

Returns the corner radius of the drop target highlighting.

Returns:

The drop target highlighting corner radius.

See also: DropHelper.Options.hasHighlightCornerRadiusPx()

public boolean hasHighlightCornerRadiusPx()

Indicates whether or not a corner radius has been set for the drop target highlighting. If not, a default is used.

Returns:

True if a corner radius has been set, false otherwise.

public boolean shouldAcceptDragsWithLocalState()

Indicates whether or not the app should respond to drag events when the drag operation contains . 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:

True if drag events will be accepted when the local state is non-null, otherwise false.

public java.util.List<EditText> getInnerEditTexts()

Returns a list of the elements contained in the drop target view hierarchy. A list of EditText elements is supplied when building this DropHelper.Options instance (see DropHelper.Options.Builder.addInnerEditTexts(EditText...)).

Returns:

The list of drop target EditText elements.