summaryrefslogtreecommitdiff
path: root/libs/androidfw/StringPool.cpp
diff options
context:
space:
mode:
author Riddle Hsu <riddlehsu@google.com> 2024-02-26 21:47:10 -0600
committer Riddle Hsu <riddlehsu@google.com> 2024-02-27 21:32:37 +0800
commit86b8389a53c35089d8bc16a7e0f70b27e5e5cccd (patch)
tree4d63a9c049d6f044f8b882fe2cced81ca335887a /libs/androidfw/StringPool.cpp
parent17f39ef01b9ba85f14ccac7e952305d674b479ba (diff)
Skip surface placement if the given insets will not change
This reduces the amount of surface placement: 2~3 times when notification shade expands or collapses. 7 times when display rotates. 6~9 times when fold state changes. Currently even if the client knows the insets are not changed, it still need to tell server side to clear a pending state: 1. Client performs relayout with RELAYOUT_INSETS_PENDING if there has a insets listener. That sets WindowState#mGivenInsetsPending to true. 2. The listener assigns the insets according to the result of relayout. 3. Client calls WindowSession#setInsets to send the insets and consume the pending state mGivenInsetsPending (set to false). Besides, by combing the conditions of mGivenInsetsPending to client side, it can reduce IPC calls such as 3 times setInsets from nav bar. Bug: 294796470 Test: atest WindowInsetsControllerTests Change-Id: Ice3320a4b694c771332107e4d8c77927e0260c8b
Diffstat (limited to 'libs/androidfw/StringPool.cpp')
0 files changed, 0 insertions, 0 deletions