public class PenEvent extends Event<PenListener> implements java.lang.Cloneable
A pen drag occurs when the pen moves while the screen is pressed.
Event.Type<H>
Modifier and Type | Field and Description |
---|---|
int |
absoluteX
The absolute x location of the event.
|
int |
absoluteY
The absolute y location of the event.
|
protected static java.lang.String[] |
EVENT_NAME |
int |
modifiers
The state of the modifier keys when the event occured.
|
static int |
PEN_DOWN
The event type for a pen or mouse down.
|
static int |
PEN_DRAG
The event type for a pen or mouse drag.
|
static int |
PEN_DRAG_END
The event type for a pen or mouse drag end.
|
static int |
PEN_DRAG_START
The event type for a pen or mouse drag start.
|
static int |
PEN_UP
The event type for a pen or mouse up.
|
int |
x
The x location of the event.
|
int |
y
The y location of the event.
|
Constructor and Description |
---|
PenEvent() |
Modifier and Type | Method and Description |
---|---|
PenEvent |
clone() |
void |
dispatch(PenListener listener) |
static java.lang.String |
getEventName(int type)
Returns the event name.
|
java.lang.String |
toString() |
PenEvent |
update(Control c,
int absoluteX,
int x,
int absoluteY,
int y,
int type,
int modifiers)
Updates this event setting also the timestamp, consumed and target.
|
clearQueue, getNextAvailableEventId, isAvailable, touch
public static final int PEN_DOWN
public static final int PEN_UP
public static final int PEN_DRAG
public static final int PEN_DRAG_START
public static final int PEN_DRAG_END
protected static final java.lang.String[] EVENT_NAME
public int x
public int y
public int absoluteX
public int absoluteY
public int modifiers
SpecialKeys
public PenEvent update(Control c, int absoluteX, int x, int absoluteY, int y, int type, int modifiers)
public static java.lang.String getEventName(int type)
public java.lang.String toString()
toString
in class Event<PenListener>
public PenEvent clone()
clone
in class java.lang.Object
public void dispatch(PenListener listener)
dispatch
in class Event<PenListener>