device admin permission added for start phone call action

This commit is contained in:
Jens 2023-08-01 22:59:05 +02:00
parent 4c66fe906e
commit 36173f2fcb
3 changed files with 6 additions and 2 deletions

View File

@ -11,8 +11,8 @@ android {
compileSdkVersion 31 compileSdkVersion 31
buildToolsVersion '29.0.2' buildToolsVersion '29.0.2'
useLibrary 'org.apache.http.legacy' useLibrary 'org.apache.http.legacy'
versionCode 133 versionCode 134
versionName "1.7.17" versionName "1.7.18"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
} }

View File

@ -706,6 +706,7 @@ public class ActivityPermissions extends Activity
case startPhoneCall: case startPhoneCall:
addToArrayListUnique(Manifest.permission.CALL_PHONE, requiredPermissions); addToArrayListUnique(Manifest.permission.CALL_PHONE, requiredPermissions);
// addToArrayListUnique(Manifest.permission.SYSTEM_ALERT_WINDOW, requiredPermissions); // addToArrayListUnique(Manifest.permission.SYSTEM_ALERT_WINDOW, requiredPermissions);
addToArrayListUnique(Manifest.permission.BIND_DEVICE_ADMIN, requiredPermissions);
break; break;
case stopPhoneCall: case stopPhoneCall:
addToArrayListUnique(Manifest.permission.ANSWER_PHONE_CALLS, requiredPermissions); addToArrayListUnique(Manifest.permission.ANSWER_PHONE_CALLS, requiredPermissions);
@ -950,6 +951,8 @@ public class ActivityPermissions extends Activity
case Manifest.permission.BIND_DEVICE_ADMIN: case Manifest.permission.BIND_DEVICE_ADMIN:
for(String ruleName : getRulesUsing(Action.Action_Enum.turnScreenOnOrOff)) for(String ruleName : getRulesUsing(Action.Action_Enum.turnScreenOnOrOff))
usingElements.add(String.format(getResources().getString(R.string.ruleXrequiresThis), ruleName)); usingElements.add(String.format(getResources().getString(R.string.ruleXrequiresThis), ruleName));
for(String ruleName : getRulesUsing(Action.Action_Enum.startPhoneCall))
usingElements.add(String.format(getResources().getString(R.string.ruleXrequiresThis), ruleName));
break; break;
case Manifest.permission.REQUEST_IGNORE_BATTERY_OPTIMIZATIONS: case Manifest.permission.REQUEST_IGNORE_BATTERY_OPTIMIZATIONS:
usingElements.add(getResources().getString(R.string.recommendedForBetterReliability)); usingElements.add(getResources().getString(R.string.recommendedForBetterReliability));

View File

@ -0,0 +1 @@
* Fixed: Added device admin permission for start-phone-call action