diff --git a/app/src/main/assets/components/lwjgl3/lwjgl-glfw-classes.jar b/app/src/main/assets/components/lwjgl3/lwjgl-glfw-classes.jar index 04524cfcf..bd2ccd092 100644 Binary files a/app/src/main/assets/components/lwjgl3/lwjgl-glfw-classes.jar and b/app/src/main/assets/components/lwjgl3/lwjgl-glfw-classes.jar differ diff --git a/app/src/main/assets/components/lwjgl3/lwjgl-glfw-classes.jar.z b/app/src/main/assets/components/lwjgl3/lwjgl-glfw-classes.jar.z new file mode 100644 index 000000000..04524cfcf Binary files /dev/null and b/app/src/main/assets/components/lwjgl3/lwjgl-glfw-classes.jar.z differ diff --git a/app/src/main/java/net/kdt/pojavlaunch/PojavV2Account.java b/app/src/main/java/net/kdt/pojavlaunch/PojavV2Account.java new file mode 100644 index 000000000..42c20bdfe --- /dev/null +++ b/app/src/main/java/net/kdt/pojavlaunch/PojavV2Account.java @@ -0,0 +1,6 @@ +package net.kdt.pojavlaunch; + +public class PojavV2Account +{ + +} diff --git a/app/src/main/java/net/kdt/pojavlaunch/installers/LegacyOptifineInstaller.java b/app/src/main/java/net/kdt/pojavlaunch/installers/LegacyOptifineInstaller.java new file mode 100644 index 000000000..99b316bd2 --- /dev/null +++ b/app/src/main/java/net/kdt/pojavlaunch/installers/LegacyOptifineInstaller.java @@ -0,0 +1,23 @@ +package net.kdt.pojavlaunch.installers; + +import android.content.*; +import java.io.*; +import java.util.jar.*; +import net.kdt.pojavlaunch.*; +import java.nio.charset.*; +import net.kdt.pojavlaunch.value.*; +import org.apache.commons.io.*; +import com.google.gson.*; +import java.util.zip.*; + +public class LegacyOptifineInstaller extends BaseInstaller { + public LegacyOptifineInstaller(BaseInstaller i) { + from(i); + } + + @Override + public int install(JavaGUILauncherActivity ctx) throws IOException { + + return 0; + } +} diff --git a/app/src/main/jni/egl_bridge.c b/app/src/main/jni/egl_bridge.c index 04686c739..e46279a5e 100644 --- a/app/src/main/jni/egl_bridge.c +++ b/app/src/main/jni/egl_bridge.c @@ -64,10 +64,6 @@ JNIEXPORT jlong JNICALL Java_org_lwjgl_glfw_GLFW_nativeEglGetCurrentContext(JNIE } JNIEXPORT jboolean JNICALL Java_org_lwjgl_glfw_GLFW_nativeEglInit(JNIEnv* env, jclass clazz) { - return JNI_TRUE; -} - -JNIEXPORT jboolean JNICALL Java_org_lwjgl_glfw_GLFW_nativeEglMakeCurrent(JNIEnv* env, jclass clazz) { static const EGLint ctx_attribs[] = { EGL_CONTEXT_CLIENT_VERSION, 2, EGL_NONE @@ -151,17 +147,24 @@ JNIEXPORT jboolean JNICALL Java_org_lwjgl_glfw_GLFW_nativeEglMakeCurrent(JNIEnv* printf("EGLBridge: OpenGL ES from eglQueryContext: %i\n", val); // assert(val >= 2); } - - // return JNI_TRUE; - printf("EGLBridge: Making current\n"); - printf("EGLBridge: EGLContext=%p, EGLDisplay=%p, EGLSurface=%p\n", - potatoBridge.eglContext, - potatoBridge.eglDisplay, - potatoBridge.eglSurface - ); + return JNI_TRUE; +} + +JNIEXPORT jboolean JNICALL Java_org_lwjgl_glfw_GLFW_nativeEglMakeCurrent(JNIEnv* env, jclass clazz, jlong window) { + printf("EGLBridge: Making current\n"); + printf("EGLBridge: EGLContext=%p, EGLDisplay=%p, EGLSurface=%p\n", + !window ? EGL_NO_CONTEXT : potatoBridge.eglContext, + potatoBridge.eglDisplay, + potatoBridge.eglSurface + ); - EGLBoolean success = eglMakeCurrent(potatoBridge.eglDisplay, potatoBridge.eglSurface, potatoBridge.eglSurface, potatoBridge.eglContext); + EGLBoolean success = eglMakeCurrent( + potatoBridge.eglDisplay, + potatoBridge.eglSurface, + potatoBridge.eglSurface, + !window ? EGL_NO_CONTEXT : potatoBridge.eglContext + ); if (success == EGL_FALSE) { printf("Error: eglMakeCurrent() failed: %p\n", eglGetError()); }