Interface SensorButtonListener
-
- All Known Implementing Classes:
SensorInputAdaptor,WandViewBehavior.GrabViewListener6D,WandViewBehavior.ListenerBase,WandViewBehavior.ResetViewListener,WandViewBehavior.RotationListener2D,WandViewBehavior.RotationListener6D,WandViewBehavior.ScaleListener2D,WandViewBehavior.ScaleListener6D,WandViewBehavior.TranslationListener2D,WandViewBehavior.TranslationListener6D
public interface SensorButtonListenerThis defines the interface for handling a sensor's button events in conjunction with aSensorEventAgentinstance.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.- Since:
- Java 3D 1.3
- See Also:
SensorEvent,SensorEventAgent,SensorReadListener
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidclicked(SensorEvent e)This method is currently not used bySensorEventAgent, but is included here for future possible development.voiddragged(SensorEvent e)This method is called with each invocation of thedispatchEventsmethod ofSensorEventAgentif any button bound to the listener is down and has not changed state since the last invocation.voidpressed(SensorEvent e)This method is called when a sensor's button is pressed.voidreleased(SensorEvent e)This method is called when a sensor's button is released.
-
-
-
Method Detail
-
pressed
void pressed(SensorEvent e)
This method is called when a sensor's button is pressed.- Parameters:
e- the sensor event
-
released
void released(SensorEvent e)
This method is called when a sensor's button is released.- Parameters:
e- the sensor event
-
dragged
void dragged(SensorEvent e)
This method is called with each invocation of thedispatchEventsmethod ofSensorEventAgentif 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.- Parameters:
e- the sensor event
-
clicked
void clicked(SensorEvent e)
This method is currently not used bySensorEventAgent, but is included here for future possible development. Its implementations should remain empty for the present.
-
-