Package com.jme3.input
Class AWTInput
java.lang.Object
com.jme3.input.AWTInput
- All Implemented Interfaces:
Input
- Direct Known Subclasses:
AWTKeyInput,AWTMouseInput
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected ApplicationTheJMonkey applicationthat provide the context.protected ComponentThe input node.protected final AWTContextThe context.protected static final AWTTaskExecutorprotected booleanInitializes is it.protected RawInputListenerThe raw listener. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidvoiddestroy()Ceases listening to events from the device.longvoidInitializes the native side to listen into events from the device.protected voidbooleanvoidsetInputListener(RawInputListener listener) Sets the input listener to receive events from this device.voidunbind()voidupdate()Queries the device for input.protected void
-
Field Details
-
EXECUTOR
-
context
The context. -
listener
The raw listener. -
component
The input node. -
application
TheJMonkey applicationthat provide the context. -
initialized
protected boolean initializedInitializes is it.
-
-
Constructor Details
-
AWTInput
-
-
Method Details
-
bind
-
unbind
public void unbind() -
initialize
public void initialize()Description copied from interface:InputInitializes the native side to listen into events from the device.- Specified by:
initializein interfaceInput
-
initializeImpl
protected void initializeImpl() -
update
public void update()Description copied from interface:InputQueries the device for input. All events should be sent to the RawInputListener set with setInputListener. -
updateImpl
protected void updateImpl() -
destroy
public void destroy()Description copied from interface:InputCeases listening to events from the device. -
isInitialized
public boolean isInitialized()- Specified by:
isInitializedin interfaceInput- Returns:
- True if the device has been initialized and not destroyed.
- See Also:
-
setInputListener
Description copied from interface:InputSets the input listener to receive events from this device. The appropriate events should be dispatched through the callbacks in RawInputListener.- Specified by:
setInputListenerin interfaceInput- Parameters:
listener- the desired listener
-
getInputTimeNanos
public long getInputTimeNanos()- Specified by:
getInputTimeNanosin interfaceInput- Returns:
- The current absolute time as nanoseconds. This time is expected to be relative to the time given in InputEvents time property.
-