RepaintEventpublic class RepaintEvent extends com.sun.midp.events.Event An subclass for events of REPAINT_EVENT type. These events are generated by
LCDUI for its own purposes. |
Fields Summary |
---|
int | paintX1X1 for the paint event. | int | paintY1Y1 for the paint event. | int | paintX2X2 for the paint event. | int | paintY2Y2 for the paint event. | Object | paintTargetTarget for the paint event. | int | perUseIDPer use ID for tracking events in serviceRepaints. | DisplayEventConsumer | displayTarget display of the event. |
Constructors Summary |
---|
private RepaintEvent(int type)Construct an event that has no parameters.
super(type);
|
Methods Summary |
---|
static com.sun.midp.lcdui.RepaintEvent | createRepaintEvent(DisplayEventConsumer d, int x, int y, int w, int h, java.lang.Object target)Create a repaint event.
RepaintEvent e = new RepaintEvent(EventTypes.REPAINT_EVENT);
e.setRepaintFields(d, x, y, w, h, target);
return e;
| void | setRepaintFields(DisplayEventConsumer d, int x, int y, int w, int h, java.lang.Object target)Set the fields of a repaint event.
display = d;
w += x; // convert from width, height to absolute
h += y; // x2, y2
if (x < 0) {
x = 0;
}
if (y < 0) {
y = 0;
}
paintX1 = x;
paintY1 = y;
paintX2 = w;
paintY2 = h;
paintTarget = target;
|
|