Class ListArea.Transition.State

java.lang.Object
org.luwrain.controls.ListArea.Transition.State
Enclosing interface:
ListArea.Transition

public static final class ListArea.Transition.State extends Object
Represents a possible state of the hot point: on an empty line (top or bottom), on a specific item index, or no transition possible.
  • Field Details

    • type

      public final ListArea.Transition.State.Type type
      The type of this state.
    • itemIndex

      public final int itemIndex
      The item index if type is ITEM_INDEX, otherwise -1.
  • Constructor Details

    • State

      public State(ListArea.Transition.State.Type type)
      Creates a state with the given type and no item index.
      Parameters:
      type - the state type (must not be null)
      Throws:
      NullPointerException - if type is null
    • State

      public State(int itemIndex)
      Creates a state representing an item index.
      Parameters:
      itemIndex - the index of the item