mirror of
https://github.com/xoureldeen/Vectras-VM-Android.git
synced 2026-04-30 07:19:58 +00:00
Chick
This commit is contained in:
parent
4473dec0f0
commit
54e34dbc20
15 changed files with 257 additions and 116 deletions
|
|
@ -131,6 +131,7 @@ public class MainActivity extends AppCompatActivity {
|
|||
private AlertDialog alertDialog;
|
||||
private boolean doneonstart = false;
|
||||
public static boolean isActivate = false;
|
||||
public boolean skipIDEwithARM64DialogInStartVM = false;
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle bundle) {
|
||||
|
|
@ -756,7 +757,7 @@ public class MainActivity extends AppCompatActivity {
|
|||
int versionCode = pinfo.versionCode;
|
||||
String versionName = pinfo.versionName;
|
||||
|
||||
if (versionCode < obj.getInt("versionCode") || !versionName.equals(obj.getString("versionName"))) {
|
||||
if (versionCode < obj.getInt("versionCode") || !obj.getString("versionName").contains(versionName)) {
|
||||
AlertDialog.Builder alert = new AlertDialog.Builder(activity, R.style.MainDialogTheme);
|
||||
alert.setTitle("Install the latest version")
|
||||
.setMessage(Html.fromHtml(obj.getString("Message") + "<br><br>update size:<br>" + obj.getString("size")))
|
||||
|
|
@ -951,6 +952,27 @@ public class MainActivity extends AppCompatActivity {
|
|||
}
|
||||
}
|
||||
|
||||
if (MainSettingsManager.getArch(activity).equals("ARM64") && MainSettingsManager.getIfType(activity).equals("ide") && !activity.skipIDEwithARM64DialogInStartVM) {
|
||||
AlertDialog abiAlertDialog = new AlertDialog.Builder(activity, R.style.MainDialogTheme).create();
|
||||
abiAlertDialog.setTitle(activity.getResources().getString(R.string.problem_has_been_detected));
|
||||
abiAlertDialog.setMessage(activity.getResources().getString(R.string.you_cannot_use_IDE_hard_drive_type_with_ARM64));
|
||||
abiAlertDialog.setButton(DialogInterface.BUTTON_POSITIVE, activity.getResources().getString(R.string.continuetext), new DialogInterface.OnClickListener() {
|
||||
public void onClick(DialogInterface dialog, int which) {
|
||||
activity.skipIDEwithARM64DialogInStartVM = true;
|
||||
startVM(vmName, env, itemExtra, itemPath);
|
||||
}
|
||||
});
|
||||
abiAlertDialog.setButton(DialogInterface.BUTTON_NEGATIVE, activity.getResources().getString(R.string.cancel), new DialogInterface.OnClickListener() {
|
||||
public void onClick(DialogInterface dialog, int which) {
|
||||
|
||||
}
|
||||
});
|
||||
abiAlertDialog.show();
|
||||
return;
|
||||
} else if (activity.skipIDEwithARM64DialogInStartVM) {
|
||||
activity.skipIDEwithARM64DialogInStartVM = false;
|
||||
}
|
||||
|
||||
boolean isRunning = isMyServiceRunning(MainService.class);
|
||||
|
||||
ProgressDialog progressDialog = new ProgressDialog(activity, R.style.MainDialogTheme);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue