|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
This defines the interface for handling a sensor's button events in
conjunction with a SensorEventAgent
instance.
The events passed to this listener's methods are ephemeral; they
are only valid until the listener has returned. If a listener needs to
retain the event it must be copied using the
SensorEvent(SensorEvent)
constructor.
SensorEvent
,
SensorEventAgent
,
SensorReadListener
Method Summary | |
void |
clicked(SensorEvent e)
This method is currently not used by SensorEventAgent ,
but is included here for future possible development. |
void |
dragged(SensorEvent e)
This method is called with each invocation of the dispatchEvents method of SensorEventAgent
if any button bound to the listener is down and has not changed
state since the last invocation. |
void |
pressed(SensorEvent e)
This method is called when a sensor's button is pressed. |
void |
released(SensorEvent e)
This method is called when a sensor's button is released. |
Method Detail |
public void pressed(SensorEvent e)
e
- the sensor eventpublic void released(SensorEvent e)
e
- the sensor eventpublic void dragged(SensorEvent e)
dispatchEvents
method of SensorEventAgent
if any button bound to the listener is down and has not changed
state since the last invocation. The sensor value has not
necessarily changed from the last drag event.
e
- the sensor eventpublic void clicked(SensorEvent e)
SensorEventAgent
,
but is included here for future possible development. Its
implementations should remain empty for the present.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |