Interface SwipeTracker.OnEndSwipe

Enclosing class:
SwipeTracker
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public static interface SwipeTracker.OnEndSwipe
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    onEndSwipe(double velocity, double to)
    This signal is emitted as soon as the gesture has stopped.
  • Method Details

    • onEndSwipe

      void onEndSwipe(double velocity, double to)
      This signal is emitted as soon as the gesture has stopped.

      The user is expected to animate the deceleration from the current progress
      value to @to with an animation using @velocity as the initial velocity,
      provided in pixels per second. [class@SpringAnimation] is usually a good
      fit for this.
      Parameters:
      velocity - the velocity of the swipe
      to - the progress value to animate to