Interface TouchStarted

All Superinterfaces:
TouchEvent

public interface TouchStarted extends TouchEvent
An event indicating that the touch has been initiated.
Since:
8.0.0
  • Method Details

    • newBuilder

      static TouchStarted.Builder newBuilder(List<TouchPoint> touches)
      Creates a new TouchStarted builder with the given required parameters.
      Parameters:
      touches - all touch points that are currently present on the screen
      Returns:
      a new TouchStarted.Builder instance
    • touches

      default List<TouchPoint> touches()
      Description copied from interface: TouchEvent
      All touch points that are currently present on the screen.

      The returned points correspond to the locations of touch contacts on the screen, e.g., to several fingers touching at once.

      Specified by:
      touches in interface TouchEvent
    • targetTouches

      default List<TouchPoint> targetTouches()
      Description copied from interface: TouchEvent
      The touch points that have started on the target element of this event.

      The result consists of elements from the TouchEvent.touches() list, with their ordering not preserved.

      Specified by:
      targetTouches in interface TouchEvent
    • changedTouches

      default List<TouchPoint> changedTouches()
      Description copied from interface: TouchEvent
      The touch points that contributed to the event.

      Meaning of these points varies depending on the event type.

      • For TouchStarted, it is a list of the touches that became active with this event.
      • For TouchMoved, it is a list of the touches that have changed since the last event.
      • For TouchCanceled and TouchEnded, it is a list of the touches that have just been removed, and no longer present on the screen.
      Specified by:
      changedTouches in interface TouchEvent
    • keyModifiers

      default KeyModifiers keyModifiers()
      Returns the keyboard modifiers applied.