mirror of
https://github.com/topjohnwu/Magisk.git
synced 2025-06-12 13:17:39 +02:00
Install to Second Slot -> Install to Inactive slot
This commit is contained in:
@ -121,7 +121,7 @@ public class FlashActivity extends Activity {
|
||||
case Const.Value.FLASH_MAGISK:
|
||||
new InstallMagisk(this, console, logs, uri, InstallMagisk.DIRECT_MODE).exec();
|
||||
break;
|
||||
case Const.Value.FLASH_SECOND_SLOT:
|
||||
case Const.Value.FLASH_INACTIVE_SLOT:
|
||||
new InstallMagisk(this, console, logs, uri, InstallMagisk.SECOND_SLOT_MODE).exec();
|
||||
break;
|
||||
case Const.Value.PATCH_BOOT:
|
||||
|
@ -70,7 +70,7 @@ class InstallMethodDialog extends AlertDialog.Builder {
|
||||
Intent intent = new Intent(context, FlashActivity.class);
|
||||
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK)
|
||||
.setData(uri).putExtra(Const.Key.FLASH_ACTION,
|
||||
Const.Value.FLASH_SECOND_SLOT);
|
||||
Const.Value.FLASH_INACTIVE_SLOT);
|
||||
context.startActivity(intent);
|
||||
}
|
||||
};
|
||||
@ -80,7 +80,7 @@ class InstallMethodDialog extends AlertDialog.Builder {
|
||||
});
|
||||
}
|
||||
|
||||
private class SelectBoot extends DownloadReceiver {
|
||||
private static class SelectBoot extends DownloadReceiver {
|
||||
|
||||
private Intent data;
|
||||
|
||||
|
@ -32,7 +32,7 @@ public class MagiskInstallDialog extends CustomAlertDialog {
|
||||
}
|
||||
String s = ShellUtils.fastCmd("grep_prop ro.build.ab_update");
|
||||
if (!s.isEmpty() && Boolean.parseBoolean(s)) {
|
||||
options.add(mm.getString(R.string.install_second_slot));
|
||||
options.add(mm.getString(R.string.install_inactive_slot));
|
||||
}
|
||||
new InstallMethodDialog(activity, options, filename).show();
|
||||
});
|
||||
|
Reference in New Issue
Block a user