Skip to content

Commit 3779dd1

Browse files
Maciej BiałkaJohan Redestig
authored andcommitted
Fix reporting of window visibility in WindowManagerService.
WindowManagerService (WMS) can wrongly report windows visibility due to wrong handling of "starting windows". "Starting windows" are special temporary windows that are displayed while the application is starting. Sometimes "starting windows" are considered when checking visibility what leads to not reported or wrongly reported visibility status. If visibility is not reported correctly some internal flows are not executed and WMS internal state can be wrong.
1 parent 7bb2581 commit 3779dd1

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

services/java/com/android/server/WindowManagerService.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8520,7 +8520,8 @@ void updateReportedVisibilityLocked() {
85208520
final int N = allAppWindows.size();
85218521
for (int i=0; i<N; i++) {
85228522
WindowState win = allAppWindows.get(i);
8523-
if (win == startingWindow || win.mAppFreezing) {
8523+
if (win == startingWindow || win.mAppFreezing
8524+
|| win.mAttrs.type == TYPE_APPLICATION_STARTING) {
85248525
continue;
85258526
}
85268527
if (DEBUG_VISIBILITY) {

0 commit comments

Comments
 (0)