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

Commit 6d2d5f80 authored by Treehugger Robot's avatar Treehugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Add LaunchSourceType annotation in ActivityRecord." into main

parents 05f838e9 d23d7cc9
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -482,6 +482,7 @@ final class ActivityRecord extends WindowToken implements WindowManagerService.A
    final String launchedFromPackage; // always the package who started the activity.
    @Nullable
    final String launchedFromFeatureId; // always the feature in launchedFromPackage
    @LaunchSourceType
    int mLaunchSourceType; // latest launch source type
    final Intent intent;    // the original intent that generated us
    final String shortComponentName; // the short component name of the intent
@@ -2330,6 +2331,7 @@ final class ActivityRecord extends WindowToken implements WindowManagerService.A
        mLaunchSourceType = determineLaunchSourceType(launchFromUid, caller);
    }

    @LaunchSourceType
    private int determineLaunchSourceType(int launchFromUid, WindowProcessController caller) {
        if (launchFromUid == Process.SYSTEM_UID || launchFromUid == Process.ROOT_UID) {
            return LAUNCH_SOURCE_TYPE_SYSTEM;