add support for the boneheaded method of receiving input events that is used by NativeActivity apps

currently, our "not-actually-a-queue" implementation is quite ugly,
hopefully it might be possible to make it look somewhat sane while
not needing to make it as much of a queue as it is on android
This commit is contained in:
Mis012
2022-11-11 19:18:21 +01:00
parent 231ac88dbd
commit 33b4515cb9
12 changed files with 291 additions and 36 deletions

View File

@@ -544,20 +544,19 @@ Java_android_app_NativeActivity_onSurfaceDestroyedNative(JNIEnv* env, jobject cl
}
void
Java_android_app_NativeActivity_onInputQueueCreatedNative(JNIEnv* env, jobject clazz, jlong handle, jint queuePtr)
Java_android_app_NativeActivity_onInputQueueCreatedNative(JNIEnv* env, jobject clazz, jlong handle, jlong queue)
{
printf("STUB - onInputChannelCreated_native\n");
/* if (handle != 0) {
if (handle != 0) {
struct NativeCode* code = (struct NativeCode*)handle;
if (code->callbacks.onInputQueueCreated != NULL) {
AInputQueue* queue = reinterpret_cast<AInputQueue*>(queuePtr);
code->callbacks.onInputQueueCreated(code, queue);
}
}*/
}
}
void
Java_android_app_NativeActivity_onInputQueueDestroyedNative(JNIEnv* env, jobject clazz, jlong handle, jint queuePtr)
Java_android_app_NativeActivity_onInputQueueDestroyedNative(JNIEnv* env, jobject clazz, jlong handle, jlong queuePtr)
{
printf("STUB - onInputChannelDestroyed_native\n");
/* if (handle != 0) {