changeset: 9446:8de3ea4c48c1 tag: tip user: Joseba GarcĂ­a Etxebarria date: Fri Mar 27 00:11:56 2015 +0100 summary: * Tried to add introspectionÂș to include Android API 14 functionality without bumping the SDK version diff -r 44ecb6b353cc -r 8de3ea4c48c1 android-project/src/org/libsdl/app/SDLActivity.java --- a/android-project/src/org/libsdl/app/SDLActivity.java Thu Mar 26 23:58:28 2015 +0100 +++ b/android-project/src/org/libsdl/app/SDLActivity.java Fri Mar 27 00:11:56 2015 +0100 @@ -1132,8 +1132,11 @@ if (event.getSource() == InputDevice.SOURCE_MOUSE && SDLActivity.nativeGetHint("SDL_ANDROID_SEPARATE_MOUSE_AND_TOUCH").equals("1")) { - mouseButton = 1; // For Android==12 all mouse buttons are the left button - + try { + mouseButton = event.getClass().getMethod("getButtonState").invoke(event); + } catch(Exception e) { + mouseButton = 1; // For Android==12 all mouse buttons are the left button + } SDLActivity.onNativeMouse(mouseButton, action, event.getX(0), event.getY(0)); } else { switch(action) {