diff options
author | Juan Linietsky <reduzio@gmail.com> | 2017-01-08 17:05:51 -0300 |
---|---|---|
committer | Juan Linietsky <reduzio@gmail.com> | 2017-01-08 17:06:33 -0300 |
commit | 547a57777b199f451305a6d4b6ad63fb0b2bd3ed (patch) | |
tree | 9fb9ce5851ea3ccc39c6ebce607ceeca771fd991 /platform/android | |
parent | 6323779596dea0db7f58afef7d3d3d5588ef20cb (diff) |
renamed joystick to joypad everywhere around source code!
Diffstat (limited to 'platform/android')
-rw-r--r-- | platform/android/java_glue.cpp | 10 | ||||
-rw-r--r-- | platform/android/os_android.cpp | 2 | ||||
-rw-r--r-- | platform/android/os_android.h | 4 |
3 files changed, 8 insertions, 8 deletions
diff --git a/platform/android/java_glue.cpp b/platform/android/java_glue.cpp index 6d47946263..3e8ce35910 100644 --- a/platform/android/java_glue.cpp +++ b/platform/android/java_glue.cpp @@ -642,7 +642,7 @@ struct JAndroidPointerEvent { static List<JAndroidPointerEvent> pointer_events; static List<InputEvent> key_events; -static List<OS_Android::JoystickEvent> joy_events; +static List<OS_Android::JoypadEvent> joy_events; static bool initialized=false; static Mutex *input_mutex=NULL; static Mutex *suspend_mutex=NULL; @@ -1090,7 +1090,7 @@ JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_step(JNIEnv * env, jo while (joy_events.size()) { - OS_Android::JoystickEvent event = joy_events.front()->get(); + OS_Android::JoypadEvent event = joy_events.front()->get(); os_android->process_joy_event(event); joy_events.pop_front(); @@ -1415,7 +1415,7 @@ static unsigned int android_get_keysym(unsigned int p_code) { JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_joybutton(JNIEnv * env, jobject obj, jint p_device, jint p_button, jboolean p_pressed) { - OS_Android::JoystickEvent jevent; + OS_Android::JoypadEvent jevent; jevent.device = p_device; jevent.type = OS_Android::JOY_EVENT_BUTTON; jevent.index = p_button; @@ -1428,7 +1428,7 @@ JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_joybutton(JNIEnv * en JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_joyaxis(JNIEnv * env, jobject obj, jint p_device, jint p_axis, jfloat p_value) { - OS_Android::JoystickEvent jevent; + OS_Android::JoypadEvent jevent; jevent.device = p_device; jevent.type = OS_Android::JOY_EVENT_AXIS; jevent.index = p_axis; @@ -1440,7 +1440,7 @@ JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_joyaxis(JNIEnv * env, } JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_joyhat(JNIEnv * env, jobject obj, jint p_device, jint p_hat_x, jint p_hat_y) { - OS_Android::JoystickEvent jevent; + OS_Android::JoypadEvent jevent; jevent.device = p_device; jevent.type = OS_Android::JOY_EVENT_HAT; int hat = 0; diff --git a/platform/android/os_android.cpp b/platform/android/os_android.cpp index 093064104a..e625c0d7ec 100644 --- a/platform/android/os_android.cpp +++ b/platform/android/os_android.cpp @@ -370,7 +370,7 @@ void OS_Android::main_loop_focusin(){ } -void OS_Android::process_joy_event(OS_Android::JoystickEvent p_event) { +void OS_Android::process_joy_event(OS_Android::JoypadEvent p_event) { switch (p_event.type) { case JOY_EVENT_BUTTON: diff --git a/platform/android/os_android.h b/platform/android/os_android.h index 68b50b2087..5e1fc10fd6 100644 --- a/platform/android/os_android.h +++ b/platform/android/os_android.h @@ -91,7 +91,7 @@ public: JOY_EVENT_HAT = 2 }; - struct JoystickEvent { + struct JoypadEvent { int device; int type; @@ -249,7 +249,7 @@ public: void process_magnetometer(const Vector3& p_magnetometer); void process_gyroscope(const Vector3& p_gyroscope); void process_touch(int p_what,int p_pointer, const Vector<TouchPos>& p_points); - void process_joy_event(JoystickEvent p_event); + void process_joy_event(JoypadEvent p_event); void process_event(InputEvent p_event); void init_video_mode(int p_video_width,int p_video_height); |