mirror of
https://github.com/AngelAuraMC/Amethyst-Android.git
synced 2025-09-13 06:39:54 -04:00
Merge branch 'v3_openjdk' of https://github.com/PojavLauncherTeam/PojavLauncher into v3_openjdk
This commit is contained in:
commit
0b7501c28d
@ -110,6 +110,8 @@ public class MainActivity extends AppCompatActivity implements OnTouchListener,
|
|||||||
|
|
||||||
private Button[] controlButtons;
|
private Button[] controlButtons;
|
||||||
|
|
||||||
|
private PrintStream logStream;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
private LinearLayout contentCanvas;
|
private LinearLayout contentCanvas;
|
||||||
private AWTSurfaceView contentCanvasView;
|
private AWTSurfaceView contentCanvasView;
|
||||||
@ -124,7 +126,7 @@ public class MainActivity extends AppCompatActivity implements OnTouchListener,
|
|||||||
private static final int LTYPE_PROCESS = 1;
|
private static final int LTYPE_PROCESS = 1;
|
||||||
private final int LAUNCH_TYPE = LTYPE_PROCESS;
|
private final int LAUNCH_TYPE = LTYPE_PROCESS;
|
||||||
// LTYPE_INVOCATION;
|
// LTYPE_INVOCATION;
|
||||||
|
|
||||||
// private static Collection<? extends Provider.Service> rsaPkcs1List;
|
// private static Collection<? extends Provider.Service> rsaPkcs1List;
|
||||||
|
|
||||||
private String getStr(int id) {
|
private String getStr(int id) {
|
||||||
@ -138,6 +140,11 @@ public class MainActivity extends AppCompatActivity implements OnTouchListener,
|
|||||||
setContentView(R.layout.main);
|
setContentView(R.layout.main);
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
File logFile = new File(Tools.MAIN_PATH, "latestlog.txt");
|
||||||
|
logFile.delete();
|
||||||
|
logFile.createNewFile();
|
||||||
|
logStream = new PrintStream(logFile.getAbsolutePath());
|
||||||
|
|
||||||
final View decorView = getWindow().getDecorView();
|
final View decorView = getWindow().getDecorView();
|
||||||
decorView.setOnSystemUiVisibilityChangeListener (new View.OnSystemUiVisibilityChangeListener() {
|
decorView.setOnSystemUiVisibilityChangeListener (new View.OnSystemUiVisibilityChangeListener() {
|
||||||
@Override
|
@Override
|
||||||
@ -157,6 +164,7 @@ public class MainActivity extends AppCompatActivity implements OnTouchListener,
|
|||||||
@Override
|
@Override
|
||||||
public void onExitTrapped()
|
public void onExitTrapped()
|
||||||
{
|
{
|
||||||
|
logStream.close();
|
||||||
runOnUiThread(new Runnable(){
|
runOnUiThread(new Runnable(){
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@ -1055,6 +1063,7 @@ public class MainActivity extends AppCompatActivity implements OnTouchListener,
|
|||||||
setEnvironment("HOME", Tools.MAIN_PATH);
|
setEnvironment("HOME", Tools.MAIN_PATH);
|
||||||
setEnvironment("TMPDIR", getCacheDir().getAbsolutePath());
|
setEnvironment("TMPDIR", getCacheDir().getAbsolutePath());
|
||||||
setEnvironment("LIBGL_MIPMAP", "3");
|
setEnvironment("LIBGL_MIPMAP", "3");
|
||||||
|
setEnvironment("MESA_GLSL_CACHE_DIR", getCacheDir().getAbsolutePath());
|
||||||
setEnvironment("LD_LIBRARY_PATH", "$JAVA_HOME/lib:$JAVA_HOME/lib/jli:$JAVA_HOME/lib/server");
|
setEnvironment("LD_LIBRARY_PATH", "$JAVA_HOME/lib:$JAVA_HOME/lib/jli:$JAVA_HOME/lib/server");
|
||||||
|
|
||||||
if (LAUNCH_TYPE == LTYPE_PROCESS) {
|
if (LAUNCH_TYPE == LTYPE_PROCESS) {
|
||||||
@ -1160,6 +1169,7 @@ public class MainActivity extends AppCompatActivity implements OnTouchListener,
|
|||||||
|
|
||||||
private void appendToLog(final String text, boolean checkAllow) {
|
private void appendToLog(final String text, boolean checkAllow) {
|
||||||
if (checkAllow && !isLogAllow) return;
|
if (checkAllow && !isLogAllow) return;
|
||||||
|
logStream.print(text);
|
||||||
textLog.post(new Runnable(){
|
textLog.post(new Runnable(){
|
||||||
@Override
|
@Override
|
||||||
public void run() {
|
public void run() {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user