Skip to content

Commit 4db5024

Browse files
committed
0.2.0-rc3
* Custom entry/OS support * BETA! Sailfish support * Minor improvements * Cleanup strings.xml
1 parent de8c01d commit 4db5024

File tree

19 files changed

+25
-354
lines changed

19 files changed

+25
-354
lines changed

.idea/misc.xml

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

app/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@ android {
1111
// we're not going to google play
1212
//noinspection OldTargetApi
1313
targetSdkVersion 27
14-
versionCode 2020
15-
versionName "0.2.0-rc2"
14+
versionCode 2030
15+
versionName "0.2.0-rc3"
1616
}
1717
signingConfigs {
1818
release {

app/src/main/assets/Scripts

app/src/main/java/org/androidbootmanager/app/roms/ROMsList.java

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,6 @@ public List<ROM> getROMs() {
3333
int b;
3434
switch (r.scriptname) {
3535
case "add_ubuntutouch_systemimage_haliumboot.sh":
36-
//noinspection SpellCheckingInspection
37-
case "add_ubuntutouch_sytemimage_haliumboot.sh": // this is considered deprecated
3836
r.viewname = c.getString(R.string.rom_type_add_ut_sysimg_halium);
3937
r.requiredFiles = new HashMap<>();
4038
r.requiredFiles.put("halium-boot.img", c.getString(R.string.select_halium_boot));
@@ -43,14 +41,30 @@ public List<ROM> getROMs() {
4341
r.parts.add(c.getString(R.string.select_part, c.getString(R.string.system_part)));
4442
r.parts.add(c.getString(R.string.select_part, c.getString(R.string.data_part)));
4543
r.strings = new HashMap<>();
46-
r.strings.put(c.getString(R.string.enter_rom_name), "");
44+
r.strings.put(c.getString(R.string.enter_rom_name), "Ubuntu Touch");
4745
a = new ArrayList<>(Arrays.asList(Objects.requireNonNull(SuFile.open("/data/abm/bootset/db/entries/").list())));
4846
a.removeIf((c) -> !c.contains("rom"));
4947
a.sort((c, d) -> Integer.compare(Integer.parseInt(c.replace("rom","").replace(".conf","")), Integer.parseInt(d.replace("rom","").replace(".conf",""))));
5048
b = a.size() > 0 ? Integer.parseInt(a.get(a.size()-1).replace("rom","").replace(".conf",""))+1 : 0;
5149
r.strings.put(c.getString(R.string.enter_rom_folder), "rom" + b);
5250
r.gen = (imodel, menuName, folderName) -> imodel.setCmdline(Objects.requireNonNull(imodel.getROM().getValue()).fullPath + " '" + folderName + "' '" + menuName + "' " + Objects.requireNonNull(imodel.getParts().getValue()).get(0) + " " + imodel.getParts().getValue().get(1) + " /data/data/org.androidbootmanager.app/cache/system.img /data/data/org.androidbootmanager.app/cache/halium-boot.img");
5351
break;
52+
case "add_sailfish.sh":
53+
r.viewname = c.getString(R.string.rom_type_add_sailfish);
54+
r.requiredFiles = new HashMap<>();
55+
r.requiredFiles.put("hybris-boot.img", c.getString(R.string.select_hybris_boot));
56+
r.requiredFiles.put("sailfish.img001", c.getString(R.string.select_system_image));
57+
r.parts = new ArrayList<>();
58+
r.parts.add(c.getString(R.string.select_part, c.getString(R.string.data_part)));
59+
r.strings = new HashMap<>();
60+
r.strings.put(c.getString(R.string.enter_rom_name), "SailfishOS");
61+
a = new ArrayList<>(Arrays.asList(Objects.requireNonNull(SuFile.open("/data/abm/bootset/db/entries/").list())));
62+
a.removeIf((c) -> !c.contains("rom"));
63+
a.sort((c, d) -> Integer.compare(Integer.parseInt(c.replace("rom","").replace(".conf","")), Integer.parseInt(d.replace("rom","").replace(".conf",""))));
64+
b = a.size() > 0 ? Integer.parseInt(a.get(a.size()-1).replace("rom","").replace(".conf",""))+1 : 0;
65+
r.strings.put(c.getString(R.string.enter_rom_folder), "rom" + b);
66+
r.gen = (imodel, menuName, folderName) -> imodel.setCmdline(Objects.requireNonNull(imodel.getROM().getValue()).fullPath + " '" + folderName + "' '" + menuName + "' " + Objects.requireNonNull(imodel.getParts().getValue()).get(0) + " /data/data/org.androidbootmanager.app/cache/sailfish.img001 /data/data/org.androidbootmanager.app/cache/hybris-boot.img");
67+
break;
5468
case "other_os.sh":
5569
r.viewname = c.getString(R.string.other_os);
5670
r.requiredFiles = new HashMap<>();

app/src/main/java/org/androidbootmanager/app/ui/addrom/DeviceROMInstallerWizardPageFragment.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@
2323
import org.androidbootmanager.app.R;
2424
import org.androidbootmanager.app.devices.DeviceList;
2525
import org.androidbootmanager.app.ui.activities.SplashActivity;
26-
import org.androidbootmanager.app.ui.installer.DeviceInstallerWizardPageFragment;
2726
import org.androidbootmanager.app.ui.wizard.WizardViewModel;
2827
import org.androidbootmanager.app.util.SDUtils;
2928

app/src/main/java/org/androidbootmanager/app/ui/installer/ROMNameChooserWizardPageFragment.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,8 @@
1313
import androidx.lifecycle.ViewModelProvider;
1414

1515
import org.androidbootmanager.app.R;
16-
import org.androidbootmanager.app.devices.DeviceList;
1716
import org.androidbootmanager.app.ui.wizard.WizardViewModel;
1817

19-
import java.util.Objects;
20-
2118
public class ROMNameChooserWizardPageFragment extends Fragment {
2219
protected WizardViewModel model;
2320
protected DeviceInstallerViewModel imodel;

app/src/main/java/org/androidbootmanager/app/ui/roms/ROMFragment.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,6 @@ public ViewHolder(View view) {
146146
.setCancelable(true)
147147
.setNeutralButton(R.string.cancel, (p1, p2) -> p1.dismiss())
148148
.setNegativeButton(R.string.delete, (p1, p2) -> MiscUtils.sure(requireContext(), p1, getString(R.string.delete_msg_2, e.config.get("title")), (p112, p212) -> {
149-
Log.i("ABM","tryna1");
150149
if (e.config.get("xsystem") != null && e.config.get("xdata") != null)
151150
if (e.config.get("xsystem").equals("real") || e.config.get("xdata").equals("real")) {
152151
new AlertDialog.Builder(requireContext())

app/src/main/res/layout/nav_header_main.xml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@
2727
android:textAppearance="@style/TextAppearance.AppCompat.Body1" />
2828

2929
<TextView
30-
android:id="@+id/textView"
3130
android:layout_width="wrap_content"
3231
android:layout_height="wrap_content"
3332
android:text="@string/nav_header_subtitle" />

app/src/main/res/layout/wizard_activity.xml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
33
xmlns:app="http://schemas.android.com/apk/res-auto"
4-
android:id="@+id/wizard_parent"
54
android:layout_width="match_parent"
65
android:layout_height="match_parent"
76
android:orientation="vertical">

app/src/main/res/layout/wizardpage_fragment.xml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
33
xmlns:app="http://schemas.android.com/apk/res-auto"
44
xmlns:tools="http://schemas.android.com/tools"
5-
android:id="@+id/wizardpage"
65
android:layout_width="match_parent"
76
android:layout_height="match_parent"
87
tools:context=".ui.wizard.ExampleWizardPageFragment">

0 commit comments

Comments
 (0)