Use correct calling method for jni functions
This commit is contained in:
parent
0e1732c45d
commit
922296f5eb
@ -64,9 +64,9 @@ public class SuperTuxKartActivity extends SDLActivity
|
||||
private STKEditText m_stk_edittext;
|
||||
private int m_bottom_y;
|
||||
// ------------------------------------------------------------------------
|
||||
private native void saveKeyboardHeight(int height);
|
||||
private native static void saveKeyboardHeight(int height);
|
||||
// ------------------------------------------------------------------------
|
||||
private native void saveMovedHeight(int height);
|
||||
private native static void saveMovedHeight(int height);
|
||||
// ------------------------------------------------------------------------
|
||||
private native static void addDNSSrvRecords(String name, int weight);
|
||||
// ------------------------------------------------------------------------
|
||||
|
@ -28,7 +28,7 @@ extern "C" int Android_getMovedHeight()
|
||||
return g_moved_height.load();
|
||||
}
|
||||
|
||||
#define MAKE_ANDROID_SAVE_KBD_HEIGHT_CALLBACK(x) JNIEXPORT void JNICALL Java_ ## x##_SuperTuxKartActivity_saveKeyboardHeight(JNIEnv* env, jobject this_obj, jint height)
|
||||
#define MAKE_ANDROID_SAVE_KBD_HEIGHT_CALLBACK(x) JNIEXPORT void JNICALL Java_ ## x##_SuperTuxKartActivity_saveKeyboardHeight(JNIEnv* env, jclass cls, jint height)
|
||||
#define ANDROID_SAVE_KBD_HEIGHT_CALLBACK(PKG_NAME) MAKE_ANDROID_SAVE_KBD_HEIGHT_CALLBACK(PKG_NAME)
|
||||
|
||||
extern "C"
|
||||
@ -37,7 +37,7 @@ ANDROID_SAVE_KBD_HEIGHT_CALLBACK(ANDROID_PACKAGE_CALLBACK_NAME)
|
||||
g_keyboard_height.store((int)height);
|
||||
}
|
||||
|
||||
#define MAKE_ANDROID_SAVE_MOVED_HEIGHT_CALLBACK(x) JNIEXPORT void JNICALL Java_ ## x##_SuperTuxKartActivity_saveMovedHeight(JNIEnv* env, jobject this_obj, jint height)
|
||||
#define MAKE_ANDROID_SAVE_MOVED_HEIGHT_CALLBACK(x) JNIEXPORT void JNICALL Java_ ## x##_SuperTuxKartActivity_saveMovedHeight(JNIEnv* env, jclass cls, jint height)
|
||||
#define ANDROID_SAVE_MOVED_HEIGHT_CALLBACK(PKG_NAME) MAKE_ANDROID_SAVE_MOVED_HEIGHT_CALLBACK(PKG_NAME)
|
||||
|
||||
extern "C"
|
||||
|
@ -266,7 +266,7 @@ EventPropagation TextBoxWidget::leftPressed (const int playerID)
|
||||
#error
|
||||
#endif
|
||||
|
||||
#define MAKE_EDITTEXT_CALLBACK(x) JNIEXPORT void JNICALL Java_ ## x##_STKEditText_editText2STKEditbox(JNIEnv* env, jobject this_obj, jint widget_id, jstring text, jint start, jint end, jint composing_start, jint composing_end)
|
||||
#define MAKE_EDITTEXT_CALLBACK(x) JNIEXPORT void JNICALL Java_ ## x##_STKEditText_editText2STKEditbox(JNIEnv* env, jclass cls, jint widget_id, jstring text, jint start, jint end, jint composing_start, jint composing_end)
|
||||
#define ANDROID_EDITTEXT_CALLBACK(PKG_NAME) MAKE_EDITTEXT_CALLBACK(PKG_NAME)
|
||||
|
||||
extern "C"
|
||||
@ -342,7 +342,7 @@ ANDROID_EDITTEXT_CALLBACK(ANDROID_PACKAGE_CALLBACK_NAME)
|
||||
extern void Android_toggleOnScreenKeyboard(bool show, int type, int y);
|
||||
extern bool Android_isHardwareKeyboardConnected();
|
||||
|
||||
#define MAKE_HANDLE_ACTION_NEXT_CALLBACK(x) JNIEXPORT void JNICALL Java_ ## x##_STKEditText_handleActionNext(JNIEnv* env, jobject this_obj, jint widget_id)
|
||||
#define MAKE_HANDLE_ACTION_NEXT_CALLBACK(x) JNIEXPORT void JNICALL Java_ ## x##_STKEditText_handleActionNext(JNIEnv* env, jclass cls, jint widget_id)
|
||||
#define ANDROID_HANDLE_ACTION_NEXT_CALLBACK(PKG_NAME) MAKE_HANDLE_ACTION_NEXT_CALLBACK(PKG_NAME)
|
||||
|
||||
extern "C"
|
||||
@ -411,7 +411,7 @@ ANDROID_HANDLE_ACTION_NEXT_CALLBACK(ANDROID_PACKAGE_CALLBACK_NAME)
|
||||
}
|
||||
|
||||
|
||||
#define MAKE_HANDLE_LEFT_RIGHT_CALLBACK(x) JNIEXPORT void JNICALL Java_ ## x##_STKEditText_handleLeftRight(JNIEnv* env, jobject this_obj, jboolean left, jint widget_id)
|
||||
#define MAKE_HANDLE_LEFT_RIGHT_CALLBACK(x) JNIEXPORT void JNICALL Java_ ## x##_STKEditText_handleLeftRight(JNIEnv* env, jclass cls, jboolean left, jint widget_id)
|
||||
#define ANDROID_HANDLE_LEFT_RIGHT_CALLBACK(PKG_NAME) MAKE_HANDLE_LEFT_RIGHT_CALLBACK(PKG_NAME)
|
||||
|
||||
extern "C"
|
||||
|
@ -62,7 +62,7 @@
|
||||
|
||||
std::vector<std::pair<std::string, int> >* g_list = NULL;
|
||||
|
||||
#define MAKE_ADD_DNS_SRV_RECORD_CALLBACK(x) JNIEXPORT void JNICALL Java_ ## x##_SuperTuxKartActivity_addDNSSrvRecords(JNIEnv* env, jobject this_obj, jstring name, jint weight)
|
||||
#define MAKE_ADD_DNS_SRV_RECORD_CALLBACK(x) JNIEXPORT void JNICALL Java_ ## x##_SuperTuxKartActivity_addDNSSrvRecords(JNIEnv* env, jclass cls, jstring name, jint weight)
|
||||
#define ANDROID_ADD_DNS_SRV_RECORD_CALLBACK(PKG_NAME) MAKE_ADD_DNS_SRV_RECORD_CALLBACK(PKG_NAME)
|
||||
|
||||
extern "C"
|
||||
|
Loading…
Reference in New Issue
Block a user