|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectField
rebuild.ui.component.GestureField
public abstract class GestureField
Gesture field, various gestures and system events will are processed and handled in this field.
Nested Class Summary | |
---|---|
class |
GestureField.Gesture
A gesture that was generated by a GestureField . |
Field Summary | |
---|---|
protected boolean |
gestureProcessing
Set to true if gesture processing should occur, false if otherwise. |
Constructor Summary | |
---|---|
GestureField()
|
Method Summary | |
---|---|
protected XYPoint |
getContact(int index)
Get a created contact. |
protected int |
getContactCount()
Get the number of contacts that have occurred. |
protected boolean |
interactionCanceled()
Any gesture operation was canceled. |
protected boolean |
interactionClick(boolean click)
Any click event. |
protected void |
interactionComplete()
Any interaction is complete. |
protected boolean |
interactionContact(int contact,
boolean down)
Any contact with the screen. |
protected boolean |
interactionGesture(GestureField.Gesture gesture)
Any gesture that has occurred. |
protected boolean |
interactionMove(int x,
int y)
A move event occurred. |
protected boolean |
interactionRotate(int rad)
A rotation event occurred. |
protected boolean |
interactionScale(int x,
int y)
A scale event occurred. |
protected abstract void |
layout(int width,
int height)
|
protected static void |
matrixSetIdentity(int[] mat,
int index)
Sets a 3x3 matrix to it's identity. |
protected static void |
matrixSetRotate(int[] mat,
int index,
int rotationInRad)
Sets a 3x3 matrix to a rotation matrix. |
protected static void |
matrixSetRotate(int[] mat,
int index,
int rotationInRad,
int centerX,
int centerY)
Sets a 3x3 matrix to a rotation matrix. |
protected static void |
matrixSetScale(int[] mat,
int index,
int x,
int y)
Sets a 3x3 matrix to a scale matrix. |
protected static void |
matrixSetScale(int[] mat,
int index,
int x,
int y,
int centerX,
int centerY)
Sets a 3x3 matrix to a scale matrix. |
protected static void |
matrixSetSkew(int[] mat,
int index,
int x,
int y)
Sets a 3x3 matrix to a skew matrix. |
protected static void |
matrixSetTranslate(int[] mat,
int index,
int x,
int y)
Sets a 3x3 matrix to a translation matrix. |
protected abstract void |
paint(Graphics graphics)
|
protected boolean |
touchEvent(TouchEvent message)
Touch Event handles all gesture functions, if you are using any gesture functions then you should not return without invoking this function. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected boolean gestureProcessing
Constructor Detail |
---|
public GestureField()
Method Detail |
---|
protected abstract void layout(int width, int height)
protected abstract void paint(Graphics graphics)
protected boolean interactionMove(int x, int y)
x
- The delta-X of the move in Fixed32 format.y
- The delta-Y of the move in Fixed32 format.
protected boolean interactionScale(int x, int y)
x
- The delta scale of the X coordinate in Fixed32 format.y
- The delta scale of the Y coordinate in Fixed32 format.
protected boolean interactionRotate(int rad)
rad
- The delta rotation of the event in Fixed32 format.
protected boolean interactionGesture(GestureField.Gesture gesture)
protected boolean interactionCanceled()
protected boolean interactionClick(boolean click)
click
- true if the event was a click, false if it was an unclick.
protected boolean interactionContact(int contact, boolean down)
contact
- The contact that occurred (1 for first contact, 2 for second contact, etc.).down
- true if the contact touched the screen, false if it was removed.
protected void interactionComplete()
protected boolean touchEvent(TouchEvent message)
Field#touchEvent(TouchEvent)
protected static void matrixSetIdentity(int[] mat, int index)
protected static void matrixSetRotate(int[] mat, int index, int rotationInRad)
rotationInRad
- The rotation in radians.protected static void matrixSetRotate(int[] mat, int index, int rotationInRad, int centerX, int centerY)
rotationInRad
- The rotation in radians.centerX
- The rotation center on the X coordinate in Fixed32 format.centerY
- The rotation center on the Y coordinate in Fixed32 format.protected static void matrixSetSkew(int[] mat, int index, int x, int y)
x
- The angle on the X coordinate to skew in Fixed32 format.y
- The angle on the Y coordinate to skew in Fixed32 format.protected static void matrixSetTranslate(int[] mat, int index, int x, int y)
x
- The X translation in Fixed32 format.y
- The Y translation in Fixed32 format.protected static void matrixSetScale(int[] mat, int index, int x, int y)
x
- The X scale in Fixed32 format.y
- The Y scale in Fixed32 format.protected static void matrixSetScale(int[] mat, int index, int x, int y, int centerX, int centerY)
x
- The X scale in Fixed32 format.y
- The Y scale in Fixed32 format.centerX
- The scaling center on the X coordinate in Fixed32 format.centerY
- The scaling center on the Y coordinate in Fixed32 format.protected int getContactCount()
protected XYPoint getContact(int index)
index
- The contact to get; 1 would be the first finger, 2 would be the second finger.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |