Class DefaultSelectionBehavior

java.lang.Object
com.levigo.jadice.web.client.tools.selectionbehavior.DefaultSelectionBehavior
All Implemented Interfaces:
SelectionBehavior

public class DefaultSelectionBehavior extends Object implements SelectionBehavior
  • Constructor Details

    • DefaultSelectionBehavior

      public DefaultSelectionBehavior()
  • Method Details

    • clear

      public void clear()
      Specified by:
      clear in interface SelectionBehavior
    • setSelection

      public void setSelection(int[] selection)
      Specified by:
      setSelection in interface SelectionBehavior
    • getSelection

      public Collection<Integer> getSelection()
      Specified by:
      getSelection in interface SelectionBehavior
    • onDown

      public void onDown(int index, boolean control, boolean shift, int button)
      Description copied from interface: SelectionBehavior
      React on mouse down.
      Specified by:
      onDown in interface SelectionBehavior
      Parameters:
      index - the page index
      control - true if control key is pressed
      shift - true if shift key is pressed
      button - the mouse button (NativeEvent.BUTTON_LEFT etc.)
    • onUp

      public void onUp(int index, boolean control, boolean shift, int button)
      Description copied from interface: SelectionBehavior
      React on mouse up.
      Specified by:
      onUp in interface SelectionBehavior
      Parameters:
      index - the page index
      control - true if control key is pressed
      shift - true if shift key is pressed
      button - the mouse button (NativeEvent.BUTTON_LEFT etc.)
    • onDragStart

      public void onDragStart(int index, boolean control, boolean shift, int button)
      Description copied from interface: SelectionBehavior
      React on drag starts.
      Specified by:
      onDragStart in interface SelectionBehavior
      Parameters:
      index - the page index
      control - true if control key is pressed
      shift - true if shift key is pressed
      button - the mouse button (NativeEvent.BUTTON_LEFT etc.)
    • select

      protected void select(int index, boolean control, boolean shift)