From d3be2f332f2f03d2cf3dd5b5e1776397f0f74f2e Mon Sep 17 00:00:00 2001 From: James Khan Date: Sat, 11 May 2019 20:19:44 +0100 Subject: [PATCH] Use enum constants instead of integer ID's --- jme3-core/src/main/java/com/jme3/input/InputManager.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/jme3-core/src/main/java/com/jme3/input/InputManager.java b/jme3-core/src/main/java/com/jme3/input/InputManager.java index 4cfbda5df..f6a34ba6e 100644 --- a/jme3-core/src/main/java/com/jme3/input/InputManager.java +++ b/jme3-core/src/main/java/com/jme3/input/InputManager.java @@ -995,11 +995,11 @@ public class InputManager implements RawInputListener { * Called when a joystick has been added or removed. * This should only be called internally. * @param joystickId the ID of the joystick. - * @param event the event that occured (connected / disconnected). + * @param state the state that occured (connected / disconnected). */ - public void fireJoystickConnectionEvent(int joystickId, int event) { + public void fireJoystickConnectionEvent(int joystickId, JoystickState state) { for (JoystickConnectionListener listener : joystickConnectionListeners) { - listener.connectionChanged(joystickId, JoystickState.fromCode(event)); + listener.connectionChanged(joystickId, state); } }