Disable install of privileged ext on Android 5.1
This commit is contained in:
parent
834c08db3c
commit
cf694b6d83
@ -206,6 +206,21 @@ public class InstallExtensionDialogActivity extends FragmentActivity {
|
||||
// hack to get theme applied (which is not automatically applied due to activity's Theme.NoDisplay
|
||||
ContextThemeWrapper theme = new ContextThemeWrapper(this, FDroidApp.getCurThemeResId());
|
||||
|
||||
// not support on Android >= 5.1
|
||||
if (android.os.Build.VERSION.SDK_INT >= 22) {
|
||||
AlertDialog.Builder alertBuilder = new AlertDialog.Builder(theme);
|
||||
alertBuilder.setMessage(R.string.system_install_not_supported);
|
||||
alertBuilder.setPositiveButton(R.string.ok, new DialogInterface.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(DialogInterface dialog, int which) {
|
||||
InstallExtensionDialogActivity.this.setResult(Activity.RESULT_CANCELED);
|
||||
InstallExtensionDialogActivity.this.finish();
|
||||
}
|
||||
});
|
||||
alertBuilder.create().show();
|
||||
return;
|
||||
}
|
||||
|
||||
AlertDialog.Builder alertBuilder = new AlertDialog.Builder(theme);
|
||||
alertBuilder.setTitle(R.string.system_install_question);
|
||||
String message = InstallExtension.create(getApplicationContext()).getWarningString();
|
||||
|
@ -295,6 +295,7 @@
|
||||
<string name="system_install_first_time_message">Looks like you have root access on your device. You can now install F-Droid Privileged Extension, tightly coupled with the Android operating system. This allows F-Droid to install, upgrade and uninstall apps on its own.</string>
|
||||
<string name="system_uninstall">Do you want to uninstall F-Droid Privileged Extension?</string>
|
||||
<string name="system_uninstall_button">Uninstall</string>
|
||||
<string name="system_install_not_supported">Installation of F-Droid Privileged Extension is currently not supported on Android 5.1 or later.</string>
|
||||
|
||||
<string name="swap_nfc_title">Touch to swap</string>
|
||||
<string name="swap_nfc_description">If your friend has F-Droid and NFC turned on touch your devices together.</string>
|
||||
|
Loading…
x
Reference in New Issue
Block a user