diff --git a/android-project/src/org/libsdl/app/SDLActivity.java b/android-project/src/org/libsdl/app/SDLActivity.java index 71280d1b3..993c98e4c 100644 --- a/android-project/src/org/libsdl/app/SDLActivity.java +++ b/android-project/src/org/libsdl/app/SDLActivity.java @@ -950,7 +950,7 @@ class SDLSurface extends SurfaceView implements SurfaceHolder.Callback, mSensorManager = (SensorManager)context.getSystemService(Context.SENSOR_SERVICE); if(Build.VERSION.SDK_INT >= 12) { - setOnGenericMotionListener(new SDLGenericMotionListener_API12()); + setOnGenericMotionListener(new SDLGenericMotionListener()); } // Some arbitrary defaults to avoid a potential division by zero diff --git a/src/core/android/SDL_android.c b/src/core/android/SDL_android.c index 8e3d87391..f7238a919 100644 --- a/src/core/android/SDL_android.c +++ b/src/core/android/SDL_android.c @@ -302,14 +302,6 @@ JNIEXPORT void JNICALL Java_org_libsdl_app_SDLActivity_onNativeMouse( Android_OnMouse(button, action, x, y); } -/* Mouse */ -JNIEXPORT void JNICALL Java_org_libsdl_app_SDLActivity_onNativeMouse( - JNIEnv* env, jclass jcls, - jint button, jint action, jfloat x, jfloat y) -{ - Android_OnMouse(button, action, x, y); -} - /* Accelerometer */ JNIEXPORT void JNICALL Java_org_libsdl_app_SDLActivity_onNativeAccel( JNIEnv* env, jclass jcls, diff --git a/src/video/android/SDL_androidmouse.c b/src/video/android/SDL_androidmouse.c index 35bc67555..12263fd12 100644 --- a/src/video/android/SDL_androidmouse.c +++ b/src/video/android/SDL_androidmouse.c @@ -24,7 +24,7 @@ #if SDL_VIDEO_DRIVER_ANDROID #include "SDL_androidmouse.h" -#include "SDL_Log.h" +#include "SDL_log.h" #include "SDL_events.h" #include "../../events/SDL_mouse_c.h" @@ -71,7 +71,7 @@ void Android_OnMouse( int androidButton, int action, float x, float y) { break; case ACTION_SCROLL: - SDL_SendMouseWheel(Android_Window, 0, x, y); + SDL_SendMouseWheel(Android_Window, 0, x, y, SDL_MOUSEWHEEL_NORMAL); break; default: diff --git a/src/video/android/SDL_androidtouch.c b/src/video/android/SDL_androidtouch.c index 4a9266e3f..1ad78dd1b 100644 --- a/src/video/android/SDL_androidtouch.c +++ b/src/video/android/SDL_androidtouch.c @@ -24,13 +24,12 @@ #include +#include "SDL_hints.h" #include "SDL_events.h" +#include "SDL_log.h" +#include "SDL_androidtouch.h" #include "../../events/SDL_mouse_c.h" #include "../../events/SDL_touch_c.h" -#include "SDL_log.h" - -#include "SDL_androidtouch.h" - #include "../../core/android/SDL_android.h" #define ACTION_DOWN 0 @@ -69,7 +68,7 @@ void Android_OnTouch(int touch_device_id_in, int pointer_finger_id_in, int actio SDL_TouchID touchDeviceId = 0; SDL_FingerID fingerId = 0; int window_x, window_y; - char * hint; + const char * hint; static SDL_FingerID pointerFingerID = 0; if (!Android_Window) {