diff options
| -rw-r--r-- | services/core/java/com/android/server/am/PendingIntentRecord.java | 14 | ||||
| -rw-r--r-- | services/tests/wmtests/src/com/android/server/wm/ActivityStarterTests.java | 5 |
2 files changed, 1 insertions, 18 deletions
diff --git a/services/core/java/com/android/server/am/PendingIntentRecord.java b/services/core/java/com/android/server/am/PendingIntentRecord.java index daf227c029a1..cb26c134f74a 100644 --- a/services/core/java/com/android/server/am/PendingIntentRecord.java +++ b/services/core/java/com/android/server/am/PendingIntentRecord.java @@ -46,7 +46,6 @@ import android.os.RemoteCallbackList; import android.os.RemoteException; import android.os.TransactionTooLargeException; import android.os.UserHandle; -import android.provider.DeviceConfig; import android.util.ArrayMap; import android.util.ArraySet; import android.util.Slog; @@ -68,9 +67,6 @@ public final class PendingIntentRecord extends IIntentSender.Stub { @EnabledAfter(targetSdkVersion = Build.VERSION_CODES.TIRAMISU) @Overridable private static final long DEFAULT_RESCIND_BAL_PRIVILEGES_FROM_PENDING_INTENT_SENDER = 244637991; - private static final String ENABLE_DEFAULT_RESCIND_BAL_PRIVILEGES_FROM_PENDING_INTENT_SENDER = - "DefaultRescindBalPrivilegesFromPendingIntentSender__" - + "enable_default_rescind_bal_privileges_from_pending_intent_sender"; public static final int FLAG_ACTIVITY_SENDER = 1 << 0; public static final int FLAG_BROADCAST_SENDER = 1 << 1; @@ -373,13 +369,6 @@ public final class PendingIntentRecord extends IIntentSender.Stub { : BackgroundStartPrivileges.NONE; } - private static boolean isDefaultRescindBalPrivilegesFromPendingIntentSenderEnabled() { - return DeviceConfig.getBoolean( - DeviceConfig.NAMESPACE_WINDOW_MANAGER, - ENABLE_DEFAULT_RESCIND_BAL_PRIVILEGES_FROM_PENDING_INTENT_SENDER, - false); // assume false if the property is unknown - } - /** * Default {@link BackgroundStartPrivileges} to be used if the intent sender has not made an * explicit choice. @@ -393,10 +382,9 @@ public final class PendingIntentRecord extends IIntentSender.Stub { }) public static BackgroundStartPrivileges getDefaultBackgroundStartPrivileges( int callingUid) { - boolean isFlagEnabled = isDefaultRescindBalPrivilegesFromPendingIntentSenderEnabled(); boolean isChangeEnabledForApp = CompatChanges.isChangeEnabled( DEFAULT_RESCIND_BAL_PRIVILEGES_FROM_PENDING_INTENT_SENDER, callingUid); - if (isFlagEnabled && isChangeEnabledForApp) { + if (isChangeEnabledForApp) { return BackgroundStartPrivileges.ALLOW_FGS; } else { return BackgroundStartPrivileges.ALLOW_BAL; diff --git a/services/tests/wmtests/src/com/android/server/wm/ActivityStarterTests.java b/services/tests/wmtests/src/com/android/server/wm/ActivityStarterTests.java index b46a3b9955dc..95fc0faf50ba 100644 --- a/services/tests/wmtests/src/com/android/server/wm/ActivityStarterTests.java +++ b/services/tests/wmtests/src/com/android/server/wm/ActivityStarterTests.java @@ -144,9 +144,6 @@ import java.util.Set; @RunWith(WindowTestRunner.class) public class ActivityStarterTests extends WindowTestsBase { - private static final String ENABLE_DEFAULT_RESCIND_BAL_PRIVILEGES_FROM_PENDING_INTENT_SENDER = - "DefaultRescindBalPrivilegesFromPendingIntentSender__" - + "enable_default_rescind_bal_privileges_from_pending_intent_sender"; private static final int PRECONDITION_NO_CALLER_APP = 1; private static final int PRECONDITION_NO_INTENT_COMPONENT = 1 << 1; private static final int PRECONDITION_NO_ACTIVITY_INFO = 1 << 2; @@ -184,8 +181,6 @@ public class ActivityStarterTests extends WindowTestsBase { doReturn(AppOpsManager.MODE_DEFAULT).when(mAppOpsManager).checkOpNoThrow( eq(AppOpsManager.OP_SYSTEM_EXEMPT_FROM_ACTIVITY_BG_START_RESTRICTION), anyInt(), any()); - mDeviceConfig.set(ENABLE_DEFAULT_RESCIND_BAL_PRIVILEGES_FROM_PENDING_INTENT_SENDER, - String.valueOf(true)); } @After |