diff options
author | Shivam Agrawal <shivamagrawal@google.com> | 2021-10-27 16:20:14 -0700 |
---|---|---|
committer | Shivam Agrawal <shivamagrawal@google.com> | 2021-11-09 17:03:50 -0800 |
commit | 9c906fbc942bbddba7fe3bc1c6e905281712a118 (patch) | |
tree | 5f19a3d128b625bbd1cdd76abceaac4fa56b83af /tools/aapt2/java/JavaClassGenerator_test.cpp | |
parent | d6cf8c85ac14a2e6bcc797e31a39a0cdab030a85 (diff) |
Include Activities That Have Not Been Assigned...
...to a Process Yet in TaskFragmentInfo
TaskFragmentInfo might be reported before an activity
has been assigned to a process, which would prevent
the activity from being reported in the TaskFragmentInfo
activities array because the activity process id does
not match the TaskFragmentOrganizer process id. However,
the activity is still reported in the running activity
count and makes the TaskFragment non-empty.
This discrepency results in unnecessary split info
callbacks because the change in TaskFragmentInfo#isEmpty
or runningActivityCount triggers an onTaskFragmentInfoChanged
callback in SplitController, which triggers a split info
callback. However, this split info callback will soon be stale
information because once the activity has been attached to a
process, the activity lifecycle listener in SplitController
will send a split info callback.
This CL uses a combination of uid and process name to check
that the activity belongs to the TaskFragmentOrganizer process
instead of the process id. uid and process name are set
during activity creation whereas pid is set afterwards, which
causes the discrepency.
Bug: b/204193051 b/205240942 b/204721225 b/204405410
Test: atest CtsWindowManagerJetpackTestCases:ActivityEmbeddingLaunchTests
Change-Id: Icfa28325da0278d2fb70e1111ffd39412b370bdb
Diffstat (limited to 'tools/aapt2/java/JavaClassGenerator_test.cpp')
0 files changed, 0 insertions, 0 deletions