summaryrefslogtreecommitdiff
path: root/core/java/android/inputmethodservice/AbstractInputMethodService.java
diff options
context:
space:
mode:
authorRiddle Hsu <riddlehsu@google.com>2021-11-09 23:17:24 -0600
committerRiddle Hsu <riddlehsu@google.com>2021-11-09 23:17:25 +0800
commit6bb5bedc5bfa35346fbaf0a1ebd43577c2143ce0 (patch)
tree5150912e0719fca3ff6e2ee770c22b581aeebf17 /core/java/android/inputmethodservice/AbstractInputMethodService.java
parent05c87f765c108cc16ef1e401c4cef49abf33592c (diff)
Skip traversal of invisible visibility change
The typical partial steps of making an existing activity visible: 1. handleAppVisibility: mAppVisible=true 2. performRestart: setWindowStopped(false) 3. performStart: Activity#makeVisible (View.VISIBLE) A stopped activity has root view visibility=INVISIBLE. So when changing mAppVisible to true, there will have an intermediate GONE->INVISIBLE (host visibility is GONE if mAppVisible is false). For root view, because it doesn't have parent, GONE and INVISIBLE are no different. It is also the same on window manager side that only cares about whehther it is visible or not. So the intermediate change can be skipped to reduce overhead. In setWindowStopped, change to use mAppVisibilityChanged to reduce the extra invocation of destroyHardwareResources(). Bug: 205693679 Test: CtsWindowManagerDeviceTestCases Change-Id: I16ac73e5f5b837e9946114bee73602bf8c8228a2
Diffstat (limited to 'core/java/android/inputmethodservice/AbstractInputMethodService.java')
0 files changed, 0 insertions, 0 deletions