mirror of
https://git.sr.ht/~eliasnaur/gio
synced 2026-07-02 07:57:29 +00:00
app: add RegisterFragment method on *Window for Android
RegisterFragment creates an instance of a Java class and registers it as a Fragment in the window's Context. Signed-off-by: Greg Pomerantz <gmp.gio@wow.st>
This commit is contained in:
committed by
Elias Naur
parent
ce76c2e996
commit
2ca2e5462f
@@ -166,3 +166,8 @@ void gio_jni_ReleaseByteArrayElements(JNIEnv *env, jbyteArray arr, jbyte *bytes)
|
||||
jsize gio_jni_GetArrayLength(JNIEnv *env, jbyteArray arr) {
|
||||
return (*env)->GetArrayLength(env, arr);
|
||||
}
|
||||
|
||||
void gio_jni_RegisterFragment(JNIEnv *env, jobject view, jmethodID mid, char* del) {
|
||||
jstring jdel = (*env)->NewStringUTF(env, del);
|
||||
(*env)->CallObjectMethod(env, view, mid, jdel);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user