From 854fe8d95ddb5f7b15fc5e1578426d6553de4490 Mon Sep 17 00:00:00 2001 From: Riddle Hsu Date: Tue, 28 Mar 2023 20:58:33 +0800 Subject: [PATCH] Do not wait for window with alpha=0 It can be considered as invisible. The legacy transition also uses similar condition in RrecentsAnimationController#isInterestingForAllDrawn. Bug: 276717081 Test: Enable -1 screen and swipe up from app, isSyncFinished() can return true directly even if the drawn state is pending. Change-Id: I711e35220e4386b4ad1a84a0f69719c9aa4e5a52 --- services/core/java/com/android/server/wm/WindowState.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/services/core/java/com/android/server/wm/WindowState.java b/services/core/java/com/android/server/wm/WindowState.java index 736f489cf99db..c1205b305e03d 100644 --- a/services/core/java/com/android/server/wm/WindowState.java +++ b/services/core/java/com/android/server/wm/WindowState.java @@ -5646,7 +5646,7 @@ class WindowState extends WindowContainer implements WindowManagerP @Override boolean isSyncFinished() { - if (!isVisibleRequested()) { + if (!isVisibleRequested() || isFullyTransparent()) { // Don't wait for invisible windows. However, we don't alter the state in case the // window becomes visible while the sync group is still active. return true;