public class DOF3Event extends MotionEvent
ALT, ALT_GRAPH, CTRL, META, NO_ID, NO_MODIFIER_MASK, SHIFT| Constructor and Description |
|---|
DOF3Event(DOF3Event prevEvent,
float x,
float y,
float z)
Construct a relative event from the given previous event, dof's and modifiers.
|
DOF3Event(DOF3Event prevEvent,
float x,
float y,
float z,
int modifiers,
int id)
Construct a relative event from the given previous event, dof's and modifiers.
|
DOF3Event(float dx,
float dy,
float dz)
Construct an absolute event from the given dof's.
|
DOF3Event(float dx,
float dy,
float dz,
int modifiers,
int id)
Construct an absolute event from the given dof's and modifiers.
|
DOF3Event(MotionEvent prevEvent,
float x,
float y,
float z)
Same as
this(prevEvent instanceof DOF3Event ? (DOF3Event) prevEvent : null, x, y, z). |
DOF3Event(MotionEvent prevEvent,
float x,
float y,
float z,
int modifiers,
int id)
Same as
this(prevEvent instanceof DOF3Event ? (DOF3Event) prevEvent : null, x, y, z, modifiers, id). |
| Modifier and Type | Method and Description |
|---|---|
DOF2Event |
dof2Event()
Reduces the event to a
DOF2Event (lossy reduction). |
float |
dx() |
float |
dy() |
float |
dz() |
boolean |
equals(Object obj) |
DOF3Event |
fire()
Same as
this.get() but sets the BogusEvent.fired() flag to true. |
DOF3Event |
flush()
Same as
this.get() but sets the BogusEvent.flushed() flag to true. |
DOF3Event |
get()
Returns a deep copy of the object.
|
int |
hashCode() |
boolean |
isNull()
Only
MotionEvents may be null. |
void |
modulate(float[] sens)
Modulate the event dofs according to
sens. |
float |
prevX() |
float |
prevY() |
float |
prevZ() |
float |
x() |
float |
y() |
float |
z() |
delay, distance, dof1Event, dof1Event, dof2Event, dof2Event, dof3Event, dof3Event, dof6Event, isAbsolute, isRelative, shortcut, speedfired, flushed, id, isAltDown, isAltGraph, isControlDown, isMetaDown, isShiftDown, modifiers, modifiersText, timestamppublic DOF3Event(float dx,
float dy,
float dz,
int modifiers,
int id)
dx - dy - dz - modifiers - id - public DOF3Event(MotionEvent prevEvent, float x, float y, float z, int modifiers, int id)
this(prevEvent instanceof DOF3Event ? (DOF3Event) prevEvent : null, x, y, z, modifiers, id).public DOF3Event(DOF3Event prevEvent, float x, float y, float z, int modifiers, int id)
If the BogusEvent.id() of the prevEvent is different then BogusEvent.id(), sets
the MotionEvent.distance(), MotionEvent.delay() and MotionEvent.speed() all to zero.
prevEvent - x - y - z - modifiers - id - public DOF3Event(float dx,
float dy,
float dz)
dx - dy - dz - public DOF3Event(MotionEvent prevEvent, float x, float y, float z)
this(prevEvent instanceof DOF3Event ? (DOF3Event) prevEvent : null, x, y, z).public DOF3Event(DOF3Event prevEvent, float x, float y, float z)
If the BogusEvent.id() of the prevEvent is different then BogusEvent.id(), sets
the MotionEvent.distance(), MotionEvent.delay() and MotionEvent.speed() all to zero.
prevEvent - x - y - z - public int hashCode()
hashCode in class MotionEventpublic boolean equals(Object obj)
equals in class MotionEventpublic DOF3Event get()
Copyable
Typical implementation should simple look like: return new Object(this).
get in interface Copyableget in class MotionEventpublic DOF3Event flush()
BogusEventthis.get() but sets the BogusEvent.flushed() flag to true. Only agents
may call this.flush in class MotionEventBogusEvent.flushed()public DOF3Event fire()
BogusEventthis.get() but sets the BogusEvent.fired() flag to true. Only agents
may call this.fire in class MotionEventBogusEvent.flushed()public float x()
MotionEvent.isRelative()public float dx()
public float prevX()
MotionEvent.isRelative()public float y()
MotionEvent.isRelative()public float dy()
public float prevY()
MotionEvent.isRelative()public float z()
MotionEvent.isRelative()public float dz()
public float prevZ()
MotionEvent.isRelative()public void modulate(float[] sens)
MotionEventsens. Only meaningful if the event
MotionEvent.isAbsolute().modulate in class MotionEventpublic boolean isNull()
BogusEventMotionEvents may be null.isNull in class BogusEventProcessing Library proscene by Jean Pierre Charalambos. (c) 2014-2017 National University of Colombia