|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectewe.graphics.PageDisplayUnit
| Field Summary | |
PageDisplay |
display
|
PageDisplayUnit |
firstChild
|
int |
flags
These are the flags for the unit. |
int |
height
|
static int |
IsHot
This is a flag indicating that this unit is clickable (e.g. |
PageDisplayUnit |
lastChild
|
PageDisplayUnit |
nextSibling
|
PageDisplayUnit |
parent
|
Object |
tip
An optional tool-tip. |
int |
width
|
int |
x
|
int |
y
|
| Constructor Summary | |
PageDisplayUnit()
|
|
| Method Summary | |
void |
addChild(PageDisplayUnit unit)
Add a child unit and update its "parent" field to point to this display. |
void |
calculateSize()
|
void |
doPaint(Graphics g)
This tells the PageDisplayUnit to display itself only - not its children. |
protected Menu |
getDefaultMenuFor(int x,
int y)
Get the default menu to display if none of the children return a menu. |
PageDisplay |
getDisplay()
This finds the PageDisplay this unit is displayed on, by going up the tree until finding a unit with the "display" variable set. |
PageDisplayUnit |
getHotUnit(int x,
int y)
This retrieves the child unit that reports itself as hot for the specified x and y co-ordinates. |
Menu |
getMenuFor(int x,
int y)
This will get a context menu for the child unit at the specific point. |
static PageDisplayUnit |
getTaggedUnit(Control taggedControl)
|
Object |
getTipFor(int x,
int y)
|
boolean |
isOnHotArea(int x,
int y)
This should return true if the point is within the hot area of the unit. |
void |
menuItemSelected(Menu m,
Object selectedItem)
This is called when a menu item is selected in the menu provided by the unit. |
boolean |
penClicked(int x,
int y)
If this returns true, then this unit has responded to the event and no further checking is necessary. |
boolean |
penDoubleClicked(int x,
int y)
If this returns true, then this unit has responded to the event and no further checking is necessary. |
boolean |
penPressed(int x,
int y)
If this returns true, then this unit has responded to the event and no further checking is necessary. |
boolean |
penReleased(int x,
int y)
If this returns true, then this unit has responded to the event and no further checking is necessary. |
void |
refresh()
This can be called to tell the display to refresh this unit. |
protected Control |
tagControl(Control m)
Use this to tag the menu with this PageDisplayUnit, so that the PageDisplay knows which one it came from. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, toString |
| Field Detail |
public PageDisplay display
public PageDisplayUnit nextSibling
public PageDisplayUnit firstChild
public PageDisplayUnit lastChild
public PageDisplayUnit parent
public int x
public int y
public int width
public int height
public Object tip
public static final int IsHot
public int flags
| Constructor Detail |
public PageDisplayUnit()
| Method Detail |
public boolean isOnHotArea(int x,
int y)
public void addChild(PageDisplayUnit unit)
public void doPaint(Graphics g)
public void calculateSize()
public PageDisplayUnit getHotUnit(int x,
int y)
public PageDisplay getDisplay()
public Object getTipFor(int x,
int y)
public Menu getMenuFor(int x,
int y)
public static PageDisplayUnit getTaggedUnit(Control taggedControl)
protected Control tagControl(Control m)
protected Menu getDefaultMenuFor(int x,
int y)
public void menuItemSelected(Menu m,
Object selectedItem)
m - The menu provided by the unit.selectedItem - usually a MenuItem object specifying the selected item.public void refresh()
public boolean penPressed(int x,
int y)
x - y -
public boolean penReleased(int x,
int y)
x - y -
public boolean penClicked(int x,
int y)
x - y -
public boolean penDoubleClicked(int x,
int y)
x - y -
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||