Installer: Add Aurora store.

This commit is contained in:
Andreas Schildbach 2019-09-06 16:01:46 +02:00
parent 12e9f64437
commit 5de2df19ac

View file

@ -23,7 +23,7 @@ import android.content.pm.PackageManager;
import okhttp3.HttpUrl;
public enum Installer {
F_DROID("F-Droid"), GOOGLE_PLAY("Google Play"), AMAZON_APPSTORE("Amazon Appstore");
F_DROID("F-Droid"), GOOGLE_PLAY("Google Play"), AMAZON_APPSTORE("Amazon Appstore"), AURORA_STORE("Aurora Store");
public final String displayName;
@ -44,6 +44,8 @@ public enum Installer {
return GOOGLE_PLAY;
if ("com.amazon.venezia".equals(installerPackageName))
return AMAZON_APPSTORE;
if ("com.aurora.store".equals(installerPackageName))
return AURORA_STORE;
return null;
}
@ -56,7 +58,7 @@ public enum Installer {
if (this == F_DROID) {
url = HttpUrl.parse("https://f-droid.org/de/packages/").newBuilder();
url.addPathSegment(application.getPackageName());
} else if (this == GOOGLE_PLAY) {
} else if (this == GOOGLE_PLAY || this == AURORA_STORE) {
url = HttpUrl.parse("https://play.google.com/store/apps/details").newBuilder();
url.addQueryParameter("id", application.getPackageName());
} else if (this == AMAZON_APPSTORE) {