Merge branch 'main' of https://github.com/FCL-Team/FoldCraftLauncher
This commit is contained in:
commit
8011692eb8
|
@ -16,10 +16,12 @@ import com.tungsten.fcl.control.MenuCallback;
|
|||
import com.tungsten.fcl.control.MenuType;
|
||||
import com.tungsten.fcl.control.GameMenu;
|
||||
import com.tungsten.fcl.control.JavaGuiMenu;
|
||||
import com.tungsten.fcl.setting.GameOption;
|
||||
import com.tungsten.fclauncher.bridge.FCLBridge;
|
||||
import com.tungsten.fclcore.util.Logging;
|
||||
import com.tungsten.fcllibrary.component.FCLActivity;
|
||||
|
||||
import java.util.Objects;
|
||||
import java.util.logging.Level;
|
||||
|
||||
public class JVMActivity extends FCLActivity implements TextureView.SurfaceTextureListener {
|
||||
|
@ -56,6 +58,11 @@ public class JVMActivity extends FCLActivity implements TextureView.SurfaceTextu
|
|||
@Override
|
||||
public void onSurfaceTextureAvailable(@NonNull SurfaceTexture surfaceTexture, int i, int i1) {
|
||||
Logging.LOG.log(Level.INFO, "surface ready, start jvm now!");
|
||||
GameOption gameOption=new GameOption(Objects.requireNonNull(menu.getBridge()).getGameDir());
|
||||
gameOption.set("fullscreen","false");
|
||||
gameOption.set("overrideWidth",""+i);
|
||||
gameOption.set("overrideHeight",""+i1);
|
||||
gameOption.save();
|
||||
surfaceTexture.setDefaultBufferSize((int) (i * fclBridge.getScaleFactor()), (int) (i1 * fclBridge.getScaleFactor()));
|
||||
fclBridge.execute(new Surface(surfaceTexture), menu.getCallbackBridge());
|
||||
fclBridge.pushEventWindow((int) (i * fclBridge.getScaleFactor()), (int) (i1 * fclBridge.getScaleFactor()));
|
||||
|
|
|
@ -94,6 +94,7 @@ public class GameMenu implements MenuCallback, View.OnClickListener {
|
|||
return menuSetting;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getCursorMode() {
|
||||
return cursorMode;
|
||||
}
|
||||
|
@ -146,6 +147,10 @@ public class GameMenu implements MenuCallback, View.OnClickListener {
|
|||
return touchPad;
|
||||
}
|
||||
|
||||
public TouchCharInput getTouchCharInput(){
|
||||
return touchCharInput;
|
||||
}
|
||||
|
||||
private void initLeftMenu() {
|
||||
|
||||
}
|
||||
|
|
|
@ -196,7 +196,7 @@ int
|
|||
JNIEXPORT void JNICALL Java_com_tungsten_fclauncher_bridge_FCLBridge_setupJLI(JNIEnv* env, jobject jobject){
|
||||
|
||||
void* handle;
|
||||
handle = dlopen("libjli.so", RTLD_LAZY);
|
||||
handle = dlopen("libjli.so", RTLD_LAZY | RTLD_GLOBAL);
|
||||
JLI_Launch = (int (*)(int, char **, int, const char**, int, const char**, const char*, const char*, const char*, const char*, jboolean, jboolean, jboolean, jint))dlsym(handle, "JLI_Launch");
|
||||
|
||||
}
|
||||
|
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading…
Reference in New Issue