Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 02ac6e45 authored by Winson Chung's avatar Winson Chung Committed by Automerger Merge Worker
Browse files

Merge "Revert "Ensure that only SysUI can override pending intent launch...

Merge "Revert "Ensure that only SysUI can override pending intent launch flags"" into qt-dev am: e6ffbc91 am: b34c8422 am: 62c12ffd am: 29eb265f am: 61c27bb4 am: ffef4ed1 am: 65c1ef9f am: f8dcd6ed am: 92ede9a4 am: 90a438c6

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/20946190



Change-Id: Ib670a1c3679a0e8ee456c47bb573165ace3f17ab
Signed-off-by: default avatarAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
parents 38961854 90a438c6
Loading
Loading
Loading
Loading
+3 −8
Original line number Diff line number Diff line
@@ -379,17 +379,12 @@ 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());
            }
            }

            // Extract options before clearing calling identity
            mergedOptions = key.options;