|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectpalmed.edit.scrollbar.Scrollbar
public final class Scrollbar
This class captures common behaviours of scrollbars.
| Constructor Summary | |
|---|---|
Scrollbar(IScrollable viewport,
IDrawer drawer)
Create a scrollbar. |
|
| Method Summary | |
|---|---|
void |
click(int offset)
Handle a click event. |
void |
drag(int offset)
Handle a drag event. |
int |
getSize()
Retrieve the size. |
int |
getWidth()
Retrieve the width. |
void |
paint(javax.microedition.lcdui.Graphics g)
Paint the scrollbar. |
void |
resize(int size)
Resize the scrollbar. |
void |
scroll(int value)
Scroll the cursor to the given value. |
void |
unclick()
Handle an unclick event. |
void |
update(int visible,
int max)
Change the length of the cursor. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Scrollbar(IScrollable viewport,
IDrawer drawer)
viewport - the viewport to registerdrawer - the scrollbar drawer| Method Detail |
|---|
public void paint(javax.microedition.lcdui.Graphics g)
g - the graphicspublic void scroll(int value)
value - the new value
public void update(int visible,
int max)
update in interface IScrollbarvisible - the number of visible elementsmax - the total number of elementspublic void resize(int size)
size - the new size in pixelspublic void click(int offset)
offset - the click offsetpublic void unclick()
public void drag(int offset)
offset - the offset to drag topublic int getWidth()
public int getSize()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||