summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWinson Chung <winsonc@google.com>2023-01-21 06:08:02 +0000
committerAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>2023-01-21 06:08:02 +0000
commitb34c84221f50b283f91701b866220691af05cd4e (patch)
treec11a77b304223c7c8670ae4d4810eccd6cb2a633
parent438e63bcaca5fd4ea5a496969f174d721125cf3e (diff)
parente6ffbc91fbd1f3e04f7c388b65e0f68659d55576 (diff)
downloadbase-b34c84221f50b283f91701b866220691af05cd4e.tar.gz
Merge "Revert "Ensure that only SysUI can override pending intent launch flags"" into qt-dev am: e6ffbc91fb
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/20946190 Change-Id: I65f295af8c9e627b531fafa717324fbf37cf3925 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
-rw-r--r--services/core/java/com/android/server/am/PendingIntentRecord.java11
1 files changed, 3 insertions, 8 deletions
diff --git a/services/core/java/com/android/server/am/PendingIntentRecord.java b/services/core/java/com/android/server/am/PendingIntentRecord.java
index 44d67ed0d642..54504c3c1e24 100644
--- a/services/core/java/com/android/server/am/PendingIntentRecord.java
+++ b/services/core/java/com/android/server/am/PendingIntentRecord.java
@@ -317,16 +317,11 @@ public final class PendingIntentRecord extends IIntentSender.Stub {
resolvedType = key.requestResolvedType;
}
- // Apply any launch flags from the ActivityOptions. This is used only by SystemUI
- // to ensure that we can launch the pending intent with a consistent launch mode even
- // if the provided PendingIntent is immutable (ie. to force an activity to launch into
- // a new task, or to launch multiple instances if supported by the app)
+ // Apply any launch flags from the ActivityOptions. This is to ensure that the caller
+ // can specify a consistent launch mode even if the PendingIntent is immutable
final ActivityOptions opts = ActivityOptions.fromBundle(options);
if (opts != null) {
- // TODO(b/254490217): Move this check into SafeActivityOptions
- if (controller.mAtmInternal.isCallerRecents(Binder.getCallingUid())) {
- finalIntent.addFlags(opts.getPendingIntentLaunchFlags());
- }
+ finalIntent.addFlags(opts.getPendingIntentLaunchFlags());
}
// Extract options before clearing calling identity