diff options
| author | 2023-04-19 08:19:51 +0000 | |
|---|---|---|
| committer | 2023-04-19 08:19:51 +0000 | |
| commit | a0237b2e83cbeb4d4d70da99a5ee87faeb3d0f36 (patch) | |
| tree | 7fce3dde15eebdb18eb957574f23e2e7be29ec45 | |
| parent | b59868db83a4ac5c4c9cec2c16239c4746f3a403 (diff) | |
| parent | a082fd92a4b91180078b2f98cb79728cdd5ff1f4 (diff) | |
Merge "Only allow NEW_TASK flag when adjusting pending intents" into qt-dev am: a082fd92a4
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/21327525
Change-Id: I6815d23a9672f31048a650bb29de39880b698194
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
| -rw-r--r-- | core/java/android/app/ActivityOptions.java | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/core/java/android/app/ActivityOptions.java b/core/java/android/app/ActivityOptions.java index 926044bffdd0..f32a21be3a8e 100644 --- a/core/java/android/app/ActivityOptions.java +++ b/core/java/android/app/ActivityOptions.java @@ -20,6 +20,8 @@ import static android.Manifest.permission.CONTROL_REMOTE_APP_TRANSITION_ANIMATIO import static android.app.ActivityTaskManager.SPLIT_SCREEN_CREATE_MODE_TOP_OR_LEFT; import static android.app.WindowConfiguration.ACTIVITY_TYPE_UNDEFINED; import static android.app.WindowConfiguration.WINDOWING_MODE_UNDEFINED; +import static android.content.Intent.FLAG_ACTIVITY_NEW_TASK; +import static android.content.Intent.FLAG_RECEIVER_FOREGROUND; import static android.view.Display.INVALID_DISPLAY; import android.annotation.Nullable; @@ -1263,7 +1265,9 @@ public class ActivityOptions { * @hide */ public int getPendingIntentLaunchFlags() { - return mPendingIntentLaunchFlags; + // b/243794108: Ignore all flags except the new task flag, to be reconsidered in b/254490217 + return mPendingIntentLaunchFlags & + (FLAG_ACTIVITY_NEW_TASK | FLAG_RECEIVER_FOREGROUND); } /** |