Class AutoScrollDragMode.AutoScrollRunnable

java.lang.Object
org.eclipse.nebula.widgets.nattable.viewport.action.AutoScrollDragMode.AutoScrollRunnable
All Implemented Interfaces:
Runnable
Enclosing class:
AutoScrollDragMode

protected class AutoScrollDragMode.AutoScrollRunnable extends Object implements Runnable
Runnable that continuously scrolls the viewport.
  • Constructor Details

  • Method Details

    • schedule

      public void schedule()
      Schedule this runnable to start with a delay of 500 ms.
    • calculateRepeatDelay

      public void calculateRepeatDelay(int horizontalDiff, int verticalDiff)
      Calculates the delay of the repeated auto-scroll execution based on the difference between the NatTable borders and the mouse cursor and the move direction that is currently active.
      Parameters:
      horizontalDiff - The horizontal difference between the NatTable border and the mouse cursor.
      verticalDiff - The vertical difference between the NatTable border and the mouse cursor.
    • cancel

      public void cancel()
      Cancels the repeated execution.
    • run

      public void run()
      Specified by:
      run in interface Runnable