Controller instances. Query the available controllers via getControllers(), add
and remove global ControllerListener instances via addListener(ControllerListener) and
removeListener(ControllerListener). The listeners will be invoked on the rendering thread. The global listeners will
be invoked for all events generated by all controllers. Polling a Controller can be done by invoking one of its getter methods.
| Modifier and Type | Field and Description |
|---|---|
| pack-priv static final ObjectMap | |
| public static String | preferredManager
The class name of a preferred |
| private static final String |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public static void | addListener(ControllerListener listener)
Add a global |
| public static void | |
| public static Array | Returns: the connected controllersReturns an array of connected |
| public static Controller | Returns: the controller the player used most recently. This might return null if there is no controller connected or the last used connector disconnected
|
| public static Array | |
| private static ControllerManager | |
| private static void | |
| public static void |
| managers | back to summary |
|---|---|
| pack-priv static final ObjectMap<Application, ControllerManager> managers | |
| preferredManager | back to summary |
|---|---|
| public static String preferredManager The class name of a preferred | |
| TAG | back to summary |
|---|---|
| private static final String TAG | |
| Controllers | back to summary |
|---|---|
| public Controllers() | |
| addListener | back to summary |
|---|---|
| public static void addListener(ControllerListener listener) Add a global | |
| clearListeners | back to summary |
|---|---|
| public static void clearListeners() Removes every global | |
| getControllers | back to summary |
|---|---|
| public static Array Returns an array of connected
| |
| getCurrent | back to summary |
|---|---|
public static Controller getCurrent()
| |
| getListeners | back to summary |
|---|---|
| public static Array Returns all listeners currently registered. Modifying this array will result in undefined behaviour. | |
| getManager | back to summary |
|---|---|
| private static ControllerManager getManager() | |
| initialize | back to summary |
|---|---|
| private static void initialize() | |
| removeListener | back to summary |
|---|---|
| public static void removeListener(ControllerListener listener) Removes a global | |