diff --git a/app/build.gradle b/app/build.gradle index 19430bb7..92375aa5 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -8,10 +8,11 @@ android { defaultConfig { applicationId "org.androidbootmanager.app" minSdkVersion 26 + // we're not going to google play //noinspection OldTargetApi targetSdkVersion 27 - versionCode 2001 - versionName "0.2.0-pre1" + versionCode 2010 + versionName "0.2.0-rc1" } signingConfigs { release { diff --git a/app/src/main/java/org/androidbootmanager/app/ui/roms/ROMFragment.java b/app/src/main/java/org/androidbootmanager/app/ui/roms/ROMFragment.java index 5ad87990..457d9569 100644 --- a/app/src/main/java/org/androidbootmanager/app/ui/roms/ROMFragment.java +++ b/app/src/main/java/org/androidbootmanager/app/ui/roms/ROMFragment.java @@ -5,11 +5,13 @@ import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; +import android.widget.EditText; import android.widget.ImageView; import android.widget.TextView; import android.widget.Toast; import androidx.annotation.NonNull; +import androidx.appcompat.app.AlertDialog; import androidx.constraintlayout.widget.ConstraintLayout; import androidx.core.content.ContextCompat; import androidx.fragment.app.Fragment; @@ -19,6 +21,7 @@ import androidx.recyclerview.widget.RecyclerView; import com.google.android.material.floatingactionbutton.FloatingActionButton; +import com.topjohnwu.superuser.Shell; import com.topjohnwu.superuser.io.SuFile; import org.androidbootmanager.app.R; @@ -27,6 +30,8 @@ import org.androidbootmanager.app.ui.wizard.WizardActivity; import org.androidbootmanager.app.util.ActionAbortedCleanlyError; import org.androidbootmanager.app.util.ConfigFile; +import org.androidbootmanager.app.util.ConfigTextWatcher; +import org.androidbootmanager.app.util.MiscUtils; import java.util.ArrayList; import java.util.List; @@ -111,8 +116,58 @@ public ViewHolder(View view) { pic = view.findViewById(R.id.entry_pic); name = view.findViewById(R.id.entry_name); container.setOnClickListener((v) -> { - // TODO - updateEntries(); + assert e != null; + ConfigFile proposed_; + try { + proposed_ = ConfigFile.importFromFile(e.file); + } catch (ActionAbortedCleanlyError actionAbortedCleanlyError) { + actionAbortedCleanlyError.printStackTrace(); + Toast.makeText(requireContext(),"Loading configuration file: Error. Action aborted cleanly. Creating new.",Toast.LENGTH_LONG).show(); + proposed_ = new ConfigFile(); + } + final ConfigFile proposed = proposed_; + View dialog = LayoutInflater.from(requireContext()).inflate(R.layout.edit_entry,null); + ((EditText) dialog.findViewById(R.id.editentryTitle)).setText(e.config.get("title")); + ((EditText) dialog.findViewById(R.id.editentryTitle)).addTextChangedListener(new ConfigTextWatcher(proposed, "title")); + ((EditText) dialog.findViewById(R.id.editentryKernel)).setText(e.config.get("linux")); + ((EditText) dialog.findViewById(R.id.editentryKernel)).addTextChangedListener(new ConfigTextWatcher(proposed, "linux")); + ((EditText) dialog.findViewById(R.id.editentryDtb)).setText(e.config.get("dtb")); + ((EditText) dialog.findViewById(R.id.editentryDtb)).addTextChangedListener(new ConfigTextWatcher(proposed, "dtb")); + ((EditText) dialog.findViewById(R.id.editentryInitrd)).setText(e.config.get("initrd")); + ((EditText) dialog.findViewById(R.id.editentryInitrd)).addTextChangedListener(new ConfigTextWatcher(proposed, "initrd")); + ((EditText) dialog.findViewById(R.id.editentryCmdline)).setText(e.config.get("options")); + ((EditText) dialog.findViewById(R.id.editentryCmdline)).addTextChangedListener(new ConfigTextWatcher(proposed, "options")); + ((EditText) dialog.findViewById(R.id.editentryDataPart)).setText(e.config.get("xdata")); + dialog.findViewById(R.id.editentryDataPart).setEnabled(false); + ((EditText) dialog.findViewById(R.id.editentrySysPart)).setText(e.config.get("xsystem")); + dialog.findViewById(R.id.editentrySysPart).setEnabled(false); + new AlertDialog.Builder(requireContext()) + .setCancelable(true) + .setNeutralButton(R.string.cancel, (p1, p2) -> p1.dismiss()) + .setNegativeButton(R.string.delete, (p1, p2) -> MiscUtils.sure(requireContext(), p1, getString(R.string.delete_msg_2, e.config.get("title")), (p112, p212) -> { + if (e.config.get("xsystem") != null && e.config.get("xdata") != null) { + if (e.config.get("xsystem").equals("real") || e.config.get("xdata").equals("real")) + new AlertDialog.Builder(requireContext()) + .setTitle(R.string.failed) + .setMessage(R.string.delete_real_rom) + .setCancelable(true) + .setNegativeButton(R.string.ok, (d, p) -> d.dismiss()) + .show(); + } else { + if (!SuFile.open(e.file).delete()) + Toast.makeText(requireContext(),"Deleting configuration file: Error.",Toast.LENGTH_LONG).show(); + Shell.su("rm -rf /data/abm/bootset/" + e.file.replace("/data/abm/bootset/lk2nd/entries/","").replace(".conf","")).submit(); + updateEntries(); + } + })) + .setPositiveButton(R.string.save, (p1, p2) -> { + e.config = proposed; + e.save(); + updateEntries(); + }) + .setTitle(R.string.edit_entry) + .setView(dialog) + .show(); }); } @@ -148,6 +203,7 @@ public void updateEntries() { Toast.makeText(requireContext(), "Loading entry: Error. Action aborted cleanly.", Toast.LENGTH_LONG).show(); } } - if (adapter != null) adapter.notifyDataSetChanged(); + adapter = new ROMRecyclerViewAdapter(entries); + recyclerView.setAdapter(adapter); } } \ No newline at end of file diff --git a/app/src/main/java/org/androidbootmanager/app/ui/sdcard/SDCardFragment.java b/app/src/main/java/org/androidbootmanager/app/ui/sdcard/SDCardFragment.java index 609ebfd4..d0c5afa3 100644 --- a/app/src/main/java/org/androidbootmanager/app/ui/sdcard/SDCardFragment.java +++ b/app/src/main/java/org/androidbootmanager/app/ui/sdcard/SDCardFragment.java @@ -28,10 +28,12 @@ import org.androidbootmanager.app.R; import org.androidbootmanager.app.devices.DeviceList; import org.androidbootmanager.app.ui.home.InstalledViewModel; +import org.androidbootmanager.app.util.MiscUtils; import org.androidbootmanager.app.util.SDUtils; import org.androidbootmanager.app.util.SOUtils; import org.jetbrains.annotations.NotNull; +import java.util.Arrays; import java.util.List; import java.util.Objects; import java.util.concurrent.atomic.AtomicReference; @@ -134,24 +136,36 @@ public ViewHolder(View view) { slider.setStepSize(1); slider.setMinSeparationValue(2048); slider.addOnChangeListener((a, b, c) -> { - List values = slider.getValues(); - float from = values.get(0); - float to = values.get(1); - if(!start.getText().toString().equals(String.valueOf(meta.dumpS(id).startSector + (long) from))) start.setText(String.valueOf(meta.dumpS(id).startSector + (long) from)); - if(!end.getText().toString().equals(String.valueOf(meta.dumpS(id).startSector + (long) to))) end.setText(String.valueOf(meta.dumpS(id).startSector + (long) to)); - if(!size.getText().toString().equals(SOUtils.humanReadableByteCountBin((long) (to - from) * meta.logicalSectorSizeBytes))) size.setText(SOUtils.humanReadableByteCountBin((long) (to - from) * meta.logicalSectorSizeBytes)); + List values = slider.getValues(); + float from = values.get(0); + float to = values.get(1); + if (!start.getText().toString().equals(String.valueOf(meta.dumpS(id).startSector + (long) from))) + start.setText(String.valueOf(meta.dumpS(id).startSector + (long) from)); + if (!end.getText().toString().equals(String.valueOf(meta.dumpS(id).startSector + (long) to))) + end.setText(String.valueOf(meta.dumpS(id).startSector + (long) to)); + if (!size.getText().toString().equals(SOUtils.humanReadableByteCountBin((long) (to - from) * meta.logicalSectorSizeBytes))) + size.setText(SOUtils.humanReadableByteCountBin((long) (to - from) * meta.logicalSectorSizeBytes)); }); dd.setOnItemSelectedListener(new AdapterView.OnItemSelectedListener() { @Override public void onItemSelected(AdapterView parent, View view, int position, long id) { if (ddresolv[position].equals(ddresolv[3])) - slider.setValues(0f,7340031f); + slider.setValues(0f, 7340031f); + } + + @Override + public void onNothingSelected(AdapterView parent) { } - @Override public void onNothingSelected(AdapterView parent) {} }); start.addTextChangedListener(new TextWatcher() { - @Override public void beforeTextChanged(CharSequence s, int start, int count, int after) {} - @Override public void onTextChanged(CharSequence s, int start, int before, int count) {} + @Override + public void beforeTextChanged(CharSequence s, int start, int count, int after) { + } + + @Override + public void onTextChanged(CharSequence s, int start, int before, int count) { + } + @Override public void afterTextChanged(Editable s) { if ((float) (Long.parseLong(s.toString()) - meta.dumpS(id).startSector) < slider.getValueFrom()) { @@ -164,17 +178,23 @@ public void afterTextChanged(Editable s) { } }); end.addTextChangedListener(new TextWatcher() { - @Override public void beforeTextChanged(CharSequence s, int start, int count, int after) {} - @Override public void onTextChanged(CharSequence s, int start, int before, int count) {} + @Override + public void beforeTextChanged(CharSequence s, int start, int count, int after) { + } + + @Override + public void onTextChanged(CharSequence s, int start, int before, int count) { + } + @Override public void afterTextChanged(Editable s) { - if ((float) (Long.parseLong(s.toString()) - meta.dumpS(id).startSector) > slider.getValueTo()) { - slider.setValues(slider.getValues().get(0), slider.getValueTo()); - } else if ((float) (Long.parseLong(s.toString()) - meta.dumpS(id).startSector) < slider.getValues().get(0)) { - slider.setValues(slider.getValues().get(0) - 1, slider.getValues().get(0)); - } else { - slider.setValues(slider.getValues().get(0), (float) (Long.parseLong(s.toString()) - meta.dumpS(id).startSector)); - } + if ((float) (Long.parseLong(s.toString()) - meta.dumpS(id).startSector) > slider.getValueTo()) { + slider.setValues(slider.getValues().get(0), slider.getValueTo()); + } else if ((float) (Long.parseLong(s.toString()) - meta.dumpS(id).startSector) < slider.getValues().get(0)) { + slider.setValues(slider.getValues().get(0) - 1, slider.getValues().get(0)); + } else { + slider.setValues(slider.getValues().get(0), (float) (Long.parseLong(s.toString()) - meta.dumpS(id).startSector)); + } } }); dd.setAdapter(new ArrayAdapter<>(requireActivity(), android.R.layout.simple_spinner_dropdown_item, new String[]{getString(R.string.portable_part), getString(R.string.data_part), getString(R.string.meta_part), getString(R.string.system_part), getString(R.string.unknown_part)})); @@ -184,30 +204,57 @@ public void afterTextChanged(Editable s) { .setTitle(getString(R.string.free_space_size, meta.dumpS(id).sizeFancy)) .setView(v) .setNegativeButton(R.string.cancel, (d, p) -> d.dismiss()) - .setPositiveButton(R.string.create, (d, p) -> { - Shell.Result r = Shell.su("sgdisk " + bdev + " --new " + meta.nid + ":" + start.getText() + ":" + end.getText() + " --typecode " + meta.nid + ":" + ddresolv[dd.getSelectedItemPosition()] + " --change-name " + meta.nid + ":'" + label.getText().toString().replace("'","") + "' && ls " + pbdev + meta.nid + (ddresolv[dd.getSelectedItemPosition()].equals("0700") ? (" && sm format public:" + meta.major + "," + (meta.minor + meta.nid)) : (ddresolv[dd.getSelectedItemPosition()].equals("8301") ? " && mkfs.ext4 " + pbdev + meta.nid : " && true"))).exec(); - new AlertDialog.Builder(requireContext()) + .setPositiveButton(R.string.create, (d, p) -> MiscUtils.w(requireContext(), R.string.creating_prog, () -> Shell.su(SDUtils.umsd(meta) + " && sgdisk " + bdev + " --new " + meta.nid + ":" + start.getText() + ":" + end.getText() + " --typecode " + meta.nid + ":" + ddresolv[dd.getSelectedItemPosition()] + " --change-name " + meta.nid + ":'" + label.getText().toString().replace("'", "") + "' && ls " + pbdev + meta.nid + (ddresolv[dd.getSelectedItemPosition()].equals("0700") ? (" && sm format public:" + meta.major + "," + (meta.minor + meta.nid)) : (ddresolv[dd.getSelectedItemPosition()].equals("8301") ? " && mkfs.ext4 " + pbdev + meta.nid : " && true"))).submit(MiscUtils.w2((r) -> new AlertDialog.Builder(requireContext()) + .setTitle(r.isSuccess() ? R.string.successful : R.string.failed) + .setMessage(String.join("\n", r.getOut()) + "\n" + String.join("\n", r.getErr()) + (String.join("", r.getOut()).contains("old") ? "IMPORTANT: Please reboot!" : "")) + .setPositiveButton(R.string.ok, (g, l) -> recyclerView.setAdapter(new SDRecyclerViewAdapter(generateMeta(DeviceList.getModel(Objects.requireNonNull(model.getCodename().getValue())))))) + .setCancelable(false) + .show())))) + .show(); + } else { + View v = getLayoutInflater().inflate(R.layout.create_part, null); + final String[] ddresolv = new String[]{"0700", "8302", "8301", "8305", "8300"}; + final EditText start = v.findViewById(R.id.create_part_start); + final EditText end = v.findViewById(R.id.create_part_end); + final EditText label = v.findViewById(R.id.create_part_label); + final Spinner dd = v.findViewById(R.id.create_part_dd); + final RangeSlider slider = v.findViewById(R.id.create_part_slide); + final TextView size = v.findViewById(R.id.create_part_size); + size.setText(meta.dumpS(id).sizeFancy); + slider.setValueFrom(0f); + slider.setValueTo((float) (meta.dumpS(id).endSector - meta.dumpS(id).startSector)); + slider.setValues(0f, (float) (meta.dumpS(id).endSector - meta.dumpS(id).startSector)); + slider.setStepSize(1); + slider.setMinSeparationValue(2048); + dd.setAdapter(new ArrayAdapter<>(requireActivity(), android.R.layout.simple_spinner_dropdown_item, new String[]{getString(R.string.portable_part), getString(R.string.data_part), getString(R.string.meta_part), getString(R.string.system_part), getString(R.string.unknown_part)})); + start.setText(String.valueOf(meta.dumpS(id).startSector)); + end.setText(String.valueOf(meta.dumpS(id).endSector)); + dd.setSelection(Arrays.asList(ddresolv).indexOf(meta.dumpS(id).code)); + start.setEnabled(false); + end.setEnabled(false); + dd.setEnabled(false); + slider.setEnabled(false); + label.setText(meta.dumpS(id).name); + new AlertDialog.Builder(requireContext()) + .setTitle(getString(R.string.partid, meta.dumpS(id).id, meta.dumpS(id).name)) + .setNeutralButton(R.string.cancel, (d, p) -> d.dismiss()) + .setNegativeButton(R.string.delete, (w, p1) -> MiscUtils.sure(requireContext(), w, getString(R.string.delete_msg, meta.dumpS(id).id, SDUtils.codes.get(meta.dumpS(id).code), meta.dumpS(id).name), (d, p) -> { + MiscUtils.w(requireContext(), R.string.delete_prog, () -> Shell.su(SDUtils.umsd(meta) + " && sgdisk " + bdev + " --delete " + meta.dumpS(id).id).submit(MiscUtils.w2((r) -> new AlertDialog.Builder(requireContext()) .setTitle(r.isSuccess() ? R.string.successful : R.string.failed) - .setMessage(String.join("\n", r.getOut()) + "\n" + String.join("\n", r.getErr()) + (String.join("",r.getOut()).contains("old") ? "IMPORTANT: Please reboot!" : "")) - .setPositiveButton(R.string.ok, (g, l) -> recyclerView.setAdapter(new SDRecyclerViewAdapter(generateMeta(DeviceList.getModel(Objects.requireNonNull(model.getCodename().getValue())))))) + .setMessage(String.join("\n", r.getOut()) + "\n" + String.join("", r.getErr()) + (String.join("", r.getOut()).contains("old") ? "IMPORTANT: Please reboot!" : "")) + .setPositiveButton(R.string.ok, (g, s) -> recyclerView.setAdapter(new SDRecyclerViewAdapter(generateMeta(DeviceList.getModel(Objects.requireNonNull(model.getCodename().getValue())))))) .setCancelable(false) - .show(); - }) + .show()))); + })) + .setPositiveButton(R.string.rename, (d, p) -> MiscUtils.w(requireContext(), R.string.renaming_prog, () -> Shell.su(SDUtils.umsd(meta) + " && sgdisk " + bdev + " --change-name " + meta.dumpS(id).id + ":'" + label.getText().toString().replace("'","") + "'").submit(MiscUtils.w2((r) -> new AlertDialog.Builder(requireContext()) + .setTitle(r.isSuccess() ? R.string.successful : R.string.failed) + .setMessage(String.join("\n", r.getOut()) + "\n" + String.join("", r.getErr()) + (String.join("", r.getOut()).contains("old") ? "IMPORTANT: Please reboot!" : "")) + .setPositiveButton(R.string.ok, (g, s) -> recyclerView.setAdapter(new SDRecyclerViewAdapter(generateMeta(DeviceList.getModel(Objects.requireNonNull(model.getCodename().getValue())))))) + .setCancelable(false) + .show())))) + .setView(v) .show(); - } else - new AlertDialog.Builder(requireContext()) - .setTitle(getString(R.string.partid, meta.dumpS(id).id, meta.dumpS(id).name)) - .setNegativeButton(R.string.cancel, (d, p) -> d.dismiss()) - .setPositiveButton(R.string.delete, (d, p) -> { - Shell.Result r = Shell.su(SDUtils.umsd(meta.dumpS(id).type, meta.major, meta.dumpS(id).minor) + " && sgdisk " + bdev + " --delete " + meta.dumpS(id).id).exec(); - new AlertDialog.Builder(requireContext()) - .setTitle(r.isSuccess() ? R.string.successful : R.string.failed) - .setMessage(String.join("\n", r.getOut()) + "\n" + String.join("", r.getErr()) + (String.join("",r.getOut()).contains("old") ? "IMPORTANT: Please reboot!" : "")) - .setPositiveButton(R.string.ok, (g, s) -> recyclerView.setAdapter(new SDRecyclerViewAdapter(generateMeta(DeviceList.getModel(Objects.requireNonNull(model.getCodename().getValue())))))) - .setCancelable(false) - .show(); - }) - .show(); + } }); } } @@ -222,6 +269,7 @@ public View onCreateView(@NonNull LayoutInflater inflater, recyclerView.setLayoutManager(recyclerLayoutManager); recyclerView.addItemDecoration(new DividerItemDecoration(recyclerView.getContext(), recyclerLayoutManager.getOrientation())); final String bdev = DeviceList.getModel(Objects.requireNonNull(model.getCodename().getValue())).bdev; + SDUtils.setupCodes(requireContext()); AtomicReference meta = new AtomicReference<>(generateMeta(DeviceList.getModel(Objects.requireNonNull(model.getCodename().getValue())))); if (meta.get() == null) { if (String.join("",Shell.su("sgdisk " + bdev + " --print").exec().getOut()).contains("invalid GPT and valid MBR")) @@ -230,22 +278,19 @@ public View onCreateView(@NonNull LayoutInflater inflater, .setCancelable(false) .setMessage(R.string.sd_mbr) .setTitle(R.string.fatal) - .setPositiveButton(R.string.convert, (d, p) -> { - Shell.Result r = Shell.su("sm unmount `sm list-volumes public` && sgdisk " + bdev + " --mbrtogpt").exec(); - new AlertDialog.Builder(requireActivity()) - .setTitle(r.isSuccess() ? R.string.successful : R.string.failed) - .setMessage(String.join("\n",r.getOut()) + "\n" + String.join("\n",r.getErr())) - .setCancelable(false) - .setPositiveButton(R.string.ok, (d2, p2) -> { - if (r.isSuccess()) { - meta.set(generateMeta(DeviceList.getModel(Objects.requireNonNull(model.getCodename().getValue())))); - recyclerView.setAdapter(new SDRecyclerViewAdapter(meta.get())); - } else { - requireActivity().finish(); - } - }) - .show(); - }) + .setPositiveButton(R.string.convert, (d, p) -> MiscUtils.w(requireContext(), R.string.convert_prog, () -> Shell.su("sm unmount `sm list-volumes public` && sgdisk " + bdev + " --mbrtogpt").submit(MiscUtils.w2((r) -> new AlertDialog.Builder(requireActivity()) + .setTitle(r.isSuccess() ? R.string.successful : R.string.failed) + .setMessage(String.join("\n", r.getOut()) + "\n" + String.join("\n", r.getErr())) + .setCancelable(false) + .setPositiveButton(R.string.ok, (d2, p2) -> { + if (r.isSuccess()) { + meta.set(generateMeta(DeviceList.getModel(Objects.requireNonNull(model.getCodename().getValue())))); + recyclerView.setAdapter(new SDRecyclerViewAdapter(meta.get())); + } else { + requireActivity().finish(); + } + }) + .show())))) .show(); else new AlertDialog.Builder(requireActivity()) diff --git a/app/src/main/java/org/androidbootmanager/app/util/MiscUtils.java b/app/src/main/java/org/androidbootmanager/app/util/MiscUtils.java new file mode 100644 index 00000000..be463c83 --- /dev/null +++ b/app/src/main/java/org/androidbootmanager/app/util/MiscUtils.java @@ -0,0 +1,51 @@ +package org.androidbootmanager.app.util; + +import android.app.AlertDialog; +import android.app.ProgressDialog; +import android.content.Context; +import android.content.DialogInterface; + +import com.topjohnwu.superuser.Shell; + +import org.androidbootmanager.app.R; + +public class MiscUtils { + public static ProgressDialog prog; + public static void sure(Context c, DialogInterface d, String msg, DialogInterface.OnClickListener v) { + d.dismiss(); + new AlertDialog.Builder(c) + .setPositiveButton(R.string.ok, v) + .setNegativeButton(R.string.cancel, (id, p) -> id.dismiss()) + .setCancelable(true) + .setTitle(R.string.sure_title) + .setMessage(msg) + .show(); + } + + public static void sure(Context c, DialogInterface d, int msg, DialogInterface.OnClickListener v) { + sure(c,d, c.getString(msg), v); + } + + public static void w(Context c, String msg, Runnable r) { + //TODO: no more deprecated ProgressDialog + prog = new ProgressDialog(c); + prog.setIndeterminate(true); + prog.setCanceledOnTouchOutside(false); + prog.setCancelable(false); + prog.setTitle(R.string.wait); + prog.setMessage(msg); + prog.show(); + r.run(); + } + + public static void w(Context c, int msg, Runnable r) { + w(c, c.getString(msg), r); + } + + public static Shell.ResultCallback w2(Shell.ResultCallback r) { + return (a) -> { + r.onResult(a); + prog.dismiss(); + }; + } +} diff --git a/app/src/main/java/org/androidbootmanager/app/util/SDUtils.java b/app/src/main/java/org/androidbootmanager/app/util/SDUtils.java index 8fef6926..e7e11995 100644 --- a/app/src/main/java/org/androidbootmanager/app/util/SDUtils.java +++ b/app/src/main/java/org/androidbootmanager/app/util/SDUtils.java @@ -149,6 +149,14 @@ public static String umsd(PartitionType t, int major, int minor) { } } + public static String umsd(SDPartitionMeta meta) { + StringBuilder s = new StringBuilder(); + for (Partition p : meta.p) + s.append(umsd(p.type, meta.major, p.minor)).append(" && "); + String e = s.toString(); + return e.substring(0, e.length()-4); + } + @Nullable public static SDPartitionMeta generateMeta(String bdev, String pbdev) { SDPartitionMeta meta; diff --git a/app/src/main/res/drawable/ic_unknown.xml b/app/src/main/res/drawable/ic_unknown.xml index b59f6878..ea3c4c71 100644 --- a/app/src/main/res/drawable/ic_unknown.xml +++ b/app/src/main/res/drawable/ic_unknown.xml @@ -1,6 +1,6 @@ diff --git a/app/src/main/res/layout/edit_entry.xml b/app/src/main/res/layout/edit_entry.xml new file mode 100644 index 00000000..2acba446 --- /dev/null +++ b/app/src/main/res/layout/edit_entry.xml @@ -0,0 +1,170 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index 053b4697..8e7a90db 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -33,7 +33,7 @@ I accept the risk, allow installation! Android Boot Manager is not installed on your device! It is only available for the Moto G5 (cedric) and for the Volla Phone (yggdrasil)! - YOU CAN LOOSE YOUR DATA! YOU CAN BRICK YOUR DEVICE! YOU CAN LOOSE YOUR IMEI (as with anything on cedric)! YOU CAN LOOSE YOUR MONEY! NOBODY IS RESPONSIBLE EXCEPT YOU! DO AT YOUR OWN RISK AND BE CAREFUL! + YOU CAN LOOSE YOUR DATA! YOU CAN BRICK YOUR DEVICE! YOU CAN LOOSE YOUR IMEI! YOU CAN LOOSE YOUR MONEY! NOBODY IS RESPONSIBLE EXCEPT YOU! DO AT YOUR OWN RISK AND BE CAREFUL! Configurator Mount Bootset Unmount Bootset @@ -57,10 +57,18 @@ The storage is currently in use. Often does Android auto-mounting or your SD card is formatted as Internal Storage. Please make sure it is not used (mounted or even modified) No storage device with ABM metadata was found but you need one for this. If you have one, press "Format". If there is no "Format" button there was no compatible storage found. Delete + This will delete partition %1$d of type %2$s labeled \'%3$s\' + This will delete the configuration file of the ROM %1$s. You need to delete the partitions on the SD card manually to prevent data loss. Config file name (No spaces, no file extension) Add ROM + Please wait… + Deleting… + Converting… + Creating… + Renaming… ROM location You cannot delete your primary ROM! + Rename Android Boot Manager is installed successfully but the app is not yet finished; blank pages and buttons that do nothing are excepted :( Android (ROM zip) Update DroidBoot @@ -112,7 +120,7 @@ Welcome! Ready! Please follow the next steps for installing Android Boot Manager. If you redecided, you can click cancel. Nothing was changed until now. Ready! Please follow the next steps for installing your ROM. If you redecided, you can click cancel. Nothing was changed until now. - Welcome to the Android Boot Manager installer. This will install Android Boot Manager on your device. Not easily undoable modifications are being done, please do not install without knowledge about it. Disclaimer follows: + Welcome to the Android Boot Manager installer. This will install Android Boot Manager on your device. Not easily undoable modifications are being done, please do not install without knowledge about it. Keep the prerequisites in mind - you may need to format stuff manually! Disclaimer follows: Next Prev @@ -139,6 +147,8 @@ Portable Storage OS System data OS User data + Data + System Please select an unused partition on your SD card configured with the following type: %1$s. Please make sure it really is the correct one, you can cancel and label it if unsure. If you didn\'t create one yet, do that first. Usage