Package org.eclipse.nebula.widgets.grid
Class GridVisibleRangeSupport
- java.lang.Object
-
- org.eclipse.nebula.widgets.grid.GridVisibleRangeSupport
-
public class GridVisibleRangeSupport extends java.lang.Object
This support class adds the possibility to get informed when the visual range in the grid is modified. E.g. to implement clever resource managementThis support is provisional and may change
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
GridVisibleRangeSupport.RangeChangedEvent
Event informing about the changestatic interface
GridVisibleRangeSupport.VisibleRangeChangedListener
Listener notified when the visible range changes
-
Field Summary
Fields Modifier and Type Field Description private Grid
grid
private Grid.GridVisibleRange
oldRange
private org.eclipse.swt.widgets.Listener
paintListener
private java.util.Collection<GridVisibleRangeSupport.VisibleRangeChangedListener>
rangeChangeListener
-
Constructor Summary
Constructors Modifier Constructor Description private
GridVisibleRangeSupport(Grid grid)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addRangeChangeListener(GridVisibleRangeSupport.VisibleRangeChangedListener listener)
Add a listener who is informed when the range is changedprivate void
calculateChange()
static GridVisibleRangeSupport
createFor(Grid grid)
Create a range support for the given grid instancevoid
removeRangeChangeListener(GridVisibleRangeSupport.VisibleRangeChangedListener listener)
Remove the listener from the ones informed when the range is changed
-
-
-
Field Detail
-
rangeChangeListener
private java.util.Collection<GridVisibleRangeSupport.VisibleRangeChangedListener> rangeChangeListener
-
grid
private Grid grid
-
oldRange
private Grid.GridVisibleRange oldRange
-
paintListener
private org.eclipse.swt.widgets.Listener paintListener
-
-
Constructor Detail
-
GridVisibleRangeSupport
private GridVisibleRangeSupport(Grid grid)
-
-
Method Detail
-
addRangeChangeListener
public void addRangeChangeListener(GridVisibleRangeSupport.VisibleRangeChangedListener listener)
Add a listener who is informed when the range is changed- Parameters:
listener
- the listener to add
-
removeRangeChangeListener
public void removeRangeChangeListener(GridVisibleRangeSupport.VisibleRangeChangedListener listener)
Remove the listener from the ones informed when the range is changed- Parameters:
listener
-
-
calculateChange
private void calculateChange()
-
createFor
public static GridVisibleRangeSupport createFor(Grid grid)
Create a range support for the given grid instance- Parameters:
grid
- the grid instance the range support is created for- Returns:
- the created range support
-
-