public abstract class AbstractMultiTouchSimulator extends java.lang.Object implements IMultiTouchSimulator, IMultiTouchInputSource
Constructor and Description |
---|
AbstractMultiTouchSimulator() |
Modifier and Type | Method and Description |
---|---|
void |
clearCursor()
Clear cursor.
|
abstract void |
deleteCursor(int id,
float x,
float y)
Delete cursor.
|
abstract void |
deleteTwoCursors(int id1,
float x1,
float y1,
int id2,
float x2,
float y2)
Delete two cursors.
|
AbstractSimCursor |
getCurrentCursor()
Gets the current cursor.
|
int |
getNewCursorID()
Gets the new cursor id.
|
void |
keyPressed(java.lang.String key)
Key pressed.
|
void |
keyReleased(java.lang.String key)
Key released.
|
void |
mouseDragged(float x,
float y,
int button)
Mouse dragged.
|
void |
mouseMoved(float x,
float y)
Mouse moved.
|
void |
mousePressed(float x,
float y,
int button)
Must supply x and y in range 0..1
|
void |
mouseReleased(float x,
float y,
int button)
Mouse released.
|
abstract void |
newCursor(int id,
float x,
float y)
New cursor.
|
void |
registerMultiTouchEventListener(IMultiTouchEventListener listener)
Register the listener to receive multi-touch events, as defined in
IMultiTouchInputListener.
|
void |
registerMultiTouchEventListener(IMultiTouchEventListener listener,
int index)
Register multi touch event listener.
|
void |
setClickSensitivity(long time,
float distance)
Determines whether two successive cursor add/remove events constitute a
'click'.
|
void |
unregisterMultiTouchEventListener(IMultiTouchEventListener listener)
Stops the listener from receiving multi-touch events.
|
abstract void |
updateCursor(int id,
float x,
float y)
Update cursor.
|
abstract void |
updateTwoCursors(int id1,
float x,
float y,
int id2,
float x2,
float y2)
Update two cursors.
|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
endListening, requiresMouseDisplay, update
public void clearCursor()
IMultiTouchSimulator
clearCursor
in interface IMultiTouchSimulator
public abstract void deleteCursor(int id, float x, float y)
IMultiTouchSimulator
deleteCursor
in interface IMultiTouchSimulator
id
- the idx
- the xy
- the ypublic abstract void deleteTwoCursors(int id1, float x1, float y1, int id2, float x2, float y2)
IMultiTouchSimulator
deleteTwoCursors
in interface IMultiTouchSimulator
id1
- the id1x1
- the xy1
- the yid2
- the id2x2
- the x2y2
- the y2public AbstractSimCursor getCurrentCursor()
public int getNewCursorID()
public void keyPressed(java.lang.String key)
key
- the keypublic void keyReleased(java.lang.String key)
key
- the keypublic void mouseDragged(float x, float y, int button)
x
- the xy
- the ybutton
- the buttonpublic void mouseMoved(float x, float y)
x
- the xy
- the ypublic void mousePressed(float x, float y, int button)
x
- y
- button
- public void mouseReleased(float x, float y, int button)
x
- the xy
- the ybutton
- the buttonpublic abstract void newCursor(int id, float x, float y)
IMultiTouchSimulator
newCursor
in interface IMultiTouchSimulator
id
- the idx
- the xy
- the ypublic void registerMultiTouchEventListener(IMultiTouchEventListener listener)
IMultiTouchInputSource
registerMultiTouchEventListener
in interface IMultiTouchInputSource
public void registerMultiTouchEventListener(IMultiTouchEventListener listener, int index)
IMultiTouchInputSource
registerMultiTouchEventListener
in interface IMultiTouchInputSource
listener
- the listenerindex
- the indexpublic void setClickSensitivity(long time, float distance)
IMultiTouchInputSource
setClickSensitivity
in interface IMultiTouchInputSource
time
- in millisecondsdistance
- in coordinate spacepublic void unregisterMultiTouchEventListener(IMultiTouchEventListener listener)
IMultiTouchInputSource
unregisterMultiTouchEventListener
in interface IMultiTouchInputSource
public abstract void updateCursor(int id, float x, float y)
IMultiTouchSimulator
updateCursor
in interface IMultiTouchSimulator
id
- the idx
- the xy
- the ypublic abstract void updateTwoCursors(int id1, float x, float y, int id2, float x2, float y2)
IMultiTouchSimulator
updateTwoCursors
in interface IMultiTouchSimulator
id1
- the id1x
- the xy
- the yid2
- the id2x2
- the x2y2
- the y2