Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename Omega to Neo in supported launchers list #90

Merged
merged 3 commits into from
Sep 7, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
31 changes: 23 additions & 8 deletions library/src/main/java/candybar/lib/helpers/LauncherHelper.java
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ private enum Launcher {
UNKNOWN, ACTION, ADW, APEX, ATOM, AVIATE, CMTHEME, GO, HOLO, HOLOHD, LAWNCHAIR,
LGHOME, LGHOME3, LUCID, MINI, NEXT, NOVA, PIXEL, SMART, SOLO, ZENUI, NOUGAT, M,
ZERO, V, ABC, EVIE, POCO, POSIDON, MICROSOFT, FLICK, BLACKBERRY, SQUARE, NIAGARA,
HYPERION, OMEGA
HYPERION, NEO, KISS
}

private static Launcher getLauncher(String packageName) {
Expand Down Expand Up @@ -126,10 +126,12 @@ private static Launcher getLauncher(String packageName) {
return Launcher.BLACKBERRY;
case "projekt.launcher":
return Launcher.HYPERION;
case "com.saggitt.omega":
return Launcher.NEO;
case "fr.neamar.kiss":
return Launcher.KISS;
default:
return Launcher.UNKNOWN;
case "com.saggitt.omega":
return Launcher.OMEGA;
}
}

Expand Down Expand Up @@ -272,6 +274,18 @@ private static void applyLauncher(@NonNull Context context, String launcherPacka
case HYPERION:
applyManual(context, launcherPackage, launcherName, "projekt.launcher.activities.SettingsActivity");
break;
case KISS:
try {
Intent kiss = new Intent(Intent.ACTION_MAIN);
kiss.setComponent(new ComponentName("fr.neamar.kiss", "fr.neamar.kiss.SettingsActivity"));
//kiss.putExtra("theme.ThemeManager", context.getPackageName());
kiss.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
context.startActivity(kiss);
((AppCompatActivity) context).finish();
} catch (ActivityNotFoundException | NullPointerException e) {
openGooglePlay(context, launcherPackage, launcherName);
}
break;
case LAWNCHAIR:
try {
LogUtil.d("@@@@@@@@@@@@@@@@@@@@@@: " + launcherPackage);
Expand Down Expand Up @@ -404,12 +418,13 @@ private static void applyLauncher(@NonNull Context context, String launcherPacka
openGooglePlay(context, launcherPackage, launcherName);
}
break;
case OMEGA:
case NEO:
try {
final Intent omega = new Intent("com.saggitt.omega.APPLY_ICONS");
omega.setComponent(ComponentName.unflattenFromString("com.saggitt.omega.iconpack.ApplyIconPackActivity"));
omega.putExtra("packageName", context.getPackageName());
context.startActivity(omega);
Intent neo = new Intent(Intent.ACTION_MAIN);
neo.setComponent(new ComponentName("com.saggitt.omega", "com.saggitt.omega.preferences.views.PreferencesActivity"));
neo.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
context.startActivity(neo);
((AppCompatActivity) context).finish();
} catch (ActivityNotFoundException | NullPointerException e) {
openGooglePlay(context, launcherPackage, launcherName);
}
Expand Down
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
9 changes: 7 additions & 2 deletions library/src/main/res/values/dashboard_launchers.xml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,8 @@
<item>Square</item> <!-- 30 -->
<item>Niagara</item> <!-- 31 -->
<item>Hyperion</item> <!-- 32 -->
<item>Omega</item> <!-- 33 -->
<item>Neo</item> <!-- 33 -->
<item>KISS</item> <!-- 34 -->
</string-array>

<array name="launcher_icons">
Expand Down Expand Up @@ -72,7 +73,8 @@
<item>@drawable/ic_launcher_square</item> <!-- 30 -->
<item>@drawable/ic_launcher_niagara</item> <!-- 31 -->
<item>@drawable/ic_launcher_hyperion</item> <!-- 32 -->
<item>@drawable/ic_launcher_omega</item> <!-- 33 -->
<item>@drawable/ic_launcher_neo</item> <!-- 33 -->
<item>@drawable/ic_launcher_kiss</item> <!-- 33 -->
</array>

<!-- Launcher Packages -->
Expand Down Expand Up @@ -111,6 +113,7 @@
<item>bitpit.launcher</item> <!-- 31 -->
<item>projekt.launcher</item> <!-- 32 -->
<item>com.saggitt.omega</item> <!-- 33 -->
<item>fr.neamar.kiss</item> <!-- 33 -->
</string-array>

<string-array name="launcher_packages_2">
Expand Down Expand Up @@ -148,6 +151,7 @@
<item>none</item> <!-- 31 -->
<item>none</item> <!-- 32 -->
<item>none</item> <!-- 33 -->
<item>none</item> <!-- 34 -->
</string-array>

<string-array name="launcher_packages_3">
Expand Down Expand Up @@ -185,6 +189,7 @@
<item>none</item> <!-- 31 -->
<item>none</item> <!-- 32 -->
<item>none</item> <!-- 33 -->
<item>none</item> <!-- 34 -->
</string-array>

</resources>
3 changes: 2 additions & 1 deletion library/src/main/res/values/launchers.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,17 +18,18 @@
<item>holo</item>
<item>holo_hd</item>
<item>hyperion</item>
<item>kiss</item>
<item>lawnchair</item>
<item>lg_home</item>
<item>lucid</item>
<!--<item>m</item>-->
<item>microsoft</item>
<!--<item>mini</item>-->
<item>neo</item>
<item>niagara</item>
<!--<item>next</item>-->
<item>nougat</item>
<item>nova</item>
<item>omega</item>
<item>pixel</item>
<item>poco</item>
<item>posidon</item>
Expand Down