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

Skip to content
Commit c15d695c authored by Riddle Hsu's avatar Riddle Hsu
Browse files

Use calling uid for metrics of starting from recents

The startActivityFromRecents can also be called from AppTask.
Without giving the uid, the launching state will always be
a new instance. And if it is starting itself again, there will be
2 launching states for the same target activity, then one of the
launch metric cannot be ended because there will be only one
drawn event.

For real Recents, it still use a standalone state. Otherwise
use the calling uid to match if there is an existing state
to reuse.

Bug: 254657154
Bug: 204488635
Test: Call below code in Activity#onCreate
       getSystemService(ActivityManager.class).getAppTasks()
           .get(0).moveToFront();
      The launch time/trace should be ended normally.
Change-Id: I23e99ea9eb47ebe8defa28d4c4a56d5d46c9a1c4
parent 099f8243
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment