mirror of
https://github.com/2009scape/2009Scape-mobile.git
synced 2026-08-01 14:19:12 -06:00
Fix: back button "soft" closing the jar installer
This commit is contained in:
parent
763e1be2d2
commit
623f7dd332
1 changed files with 12 additions and 0 deletions
|
|
@ -8,6 +8,8 @@ import android.util.*;
|
|||
import android.view.*;
|
||||
import android.widget.*;
|
||||
|
||||
import androidx.activity.OnBackPressedCallback;
|
||||
|
||||
import java.io.*;
|
||||
import java.util.*;
|
||||
|
||||
|
|
@ -155,6 +157,14 @@ public class JavaGUILauncherActivity extends BaseActivity implements View.OnTouc
|
|||
} catch (Throwable th) {
|
||||
Tools.showError(this, th, true);
|
||||
}
|
||||
|
||||
|
||||
getOnBackPressedDispatcher().addCallback(new OnBackPressedCallback(true) {
|
||||
@Override
|
||||
public void handleOnBackPressed() {
|
||||
MainActivity.dialogForceClose(JavaGUILauncherActivity.this);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
@ -165,6 +175,8 @@ public class JavaGUILauncherActivity extends BaseActivity implements View.OnTouc
|
|||
decorView.setSystemUiVisibility(uiOptions);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@Override
|
||||
public boolean onTouch(View v, MotionEvent e) {
|
||||
boolean isDown;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue