From 71c7f53df08d74cad7d868a471f6f37260639de2 Mon Sep 17 00:00:00 2001 From: Andreas Schildbach Date: Mon, 25 Oct 2021 10:00:13 +0200 Subject: [PATCH] AndroidManifest.xml: require Android 7.0 (Nougat) --- wallet/AndroidManifest.xml | 2 +- wallet/src/de/schildbach/wallet/WalletApplication.java | 2 +- .../de/schildbach/wallet/ui/preference/SettingsFragment.java | 5 ++--- 3 files changed, 4 insertions(+), 5 deletions(-) diff --git a/wallet/AndroidManifest.xml b/wallet/AndroidManifest.xml index 4b5f4ebc10..d2c1d47b1c 100644 --- a/wallet/AndroidManifest.xml +++ b/wallet/AndroidManifest.xml @@ -8,7 +8,7 @@ android:versionName="8.19"> diff --git a/wallet/src/de/schildbach/wallet/WalletApplication.java b/wallet/src/de/schildbach/wallet/WalletApplication.java index 92d8d52f8d..62ec07c934 100644 --- a/wallet/src/de/schildbach/wallet/WalletApplication.java +++ b/wallet/src/de/schildbach/wallet/WalletApplication.java @@ -354,7 +354,7 @@ public int scryptIterationsTarget() { } public boolean fullSyncCapable() { - return Build.VERSION.SDK_INT >= Build.VERSION_CODES.N && activityManager.getMemoryClass() >= 128; + return activityManager.getMemoryClass() >= 128; } public static String versionLine(final PackageInfo packageInfo) { diff --git a/wallet/src/de/schildbach/wallet/ui/preference/SettingsFragment.java b/wallet/src/de/schildbach/wallet/ui/preference/SettingsFragment.java index 1ed504e7aa..6000e9cbf9 100644 --- a/wallet/src/de/schildbach/wallet/ui/preference/SettingsFragment.java +++ b/wallet/src/de/schildbach/wallet/ui/preference/SettingsFragment.java @@ -115,9 +115,8 @@ public void onCreate(final Bundle savedInstanceState) { removeOrDisablePreference(enableExchangeRatesPreference); final Preference dataUsagePreference = findPreference(Configuration.PREFS_KEY_DATA_USAGE); - if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.N) - dataUsagePreference.setIntent(new Intent(Settings.ACTION_IGNORE_BACKGROUND_DATA_RESTRICTIONS_SETTINGS, - Uri.parse("package:" + application.getPackageName()))); + dataUsagePreference.setIntent(new Intent(Settings.ACTION_IGNORE_BACKGROUND_DATA_RESTRICTIONS_SETTINGS, + Uri.parse("package:" + application.getPackageName()))); if (dataUsagePreference.getIntent() == null || pm.resolveActivity(dataUsagePreference.getIntent(), 0) == null) removeOrDisablePreference(dataUsagePreference);