Class CellSelectionDragMode
java.lang.Object
org.eclipse.nebula.widgets.nattable.viewport.action.AutoScrollDragMode
org.eclipse.nebula.widgets.nattable.selection.action.CellSelectionDragMode
- All Implemented Interfaces:
IDragMode
- Direct Known Subclasses:
RowSelectionDragMode
Fires commands to select a range of cells when the mouse is dragged in the
viewport.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.eclipse.nebula.widgets.nattable.viewport.action.AutoScrollDragMode
AutoScrollDragMode.AutoScrollRunnable -
Field Summary
Fields inherited from class org.eclipse.nebula.widgets.nattable.viewport.action.AutoScrollDragMode
horizontalBorderOffset, verticalBorderOffset -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidfireSelectionCommand(NatTable natTable, int columnPosition, int rowPosition, boolean shiftMask, boolean controlMask) Execute a command to trigger selection.voidvoidprotected voidperformDragAction(NatTable natTable, int x, int y, SelectionLayer.MoveDirectionEnum horizontal, SelectionLayer.MoveDirectionEnum vertical) Methods inherited from class org.eclipse.nebula.widgets.nattable.viewport.action.AutoScrollDragMode
mouseMove
-
Constructor Details
-
CellSelectionDragMode
public CellSelectionDragMode()
-
-
Method Details
-
mouseDown
-
performDragAction
protected void performDragAction(NatTable natTable, int x, int y, SelectionLayer.MoveDirectionEnum horizontal, SelectionLayer.MoveDirectionEnum vertical) - Overrides:
performDragActionin classAutoScrollDragMode- Parameters:
natTable- The NatTable instance the drag operation is currently performed on.x- The x coordinate of the mouse pointer on mouse move. Corrected to be inside the NatTable client area.y- The y coordinate of the mouse pointer on mouse move. Corrected to be inside the NatTable client area.horizontal- The horizontal direction where the auto-scroll should be performed to.vertical- The vertical direction where the auto-scroll should be performed to.
-
fireSelectionCommand
public void fireSelectionCommand(NatTable natTable, int columnPosition, int rowPosition, boolean shiftMask, boolean controlMask) Execute a command to trigger selection.- Parameters:
natTable- The NatTable to execute the command on.columnPosition- The column position of the cell to select.rowPosition- The row position of the cell to select.shiftMask- Flag to configure whether the SHIFT mask is activated or not.controlMask- Flag to configure whether the CTRL mask is activated or not.
-
mouseUp
- Specified by:
mouseUpin interfaceIDragMode- Overrides:
mouseUpin classAutoScrollDragMode
-