|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.vaadin.client.widget.grid.AutoScroller
public class AutoScroller
A class for handling automatic scrolling vertically / horizontally in the Grid when the cursor is close enough the edge of the body of the grid, depending on the scroll direction chosen.
| Nested Class Summary | |
|---|---|
static interface |
AutoScroller.AutoScrollerCallback
Callback that notifies when the cursor is on top of a new row or column because of the automatic scrolling. |
static class |
AutoScroller.ScrollAxis
|
| Constructor Summary | |
|---|---|
AutoScroller(Grid<?> grid)
Creates a new instance for scrolling the given grid. |
|
| Method Summary | |
|---|---|
double |
getFrozenColumnsWidth()
|
int |
getScrollArea()
Returns the size of the auto scroll area in pixels. |
void |
setScrollArea(int px)
Set the auto scroll area height or width depending on the scrolling axis. |
void |
start(NativeEvent startEvent,
AutoScroller.ScrollAxis scrollAxis,
AutoScroller.AutoScrollerCallback callback)
Starts the automatic scrolling detection. |
void |
stop()
Stops the automatic scrolling. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public AutoScroller(Grid<?> grid)
grid - the grid to auto scroll| Method Detail |
|---|
public void start(NativeEvent startEvent,
AutoScroller.ScrollAxis scrollAxis,
AutoScroller.AutoScrollerCallback callback)
startEvent - the event that starts the automatic scrollscrollAxis - the axis along which the scrolling should happencallback - the callback for getting info about the automatic scrollingpublic void stop()
public void setScrollArea(int px)
Defaults to 100px.
px - the pixel height/width for the auto scroll area depending on
directionpublic int getScrollArea()
Defaults to 100px.
public double getFrozenColumnsWidth()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||