Merge "Prevent dismissing starting window when reopening app" into qt-dev

am: 94f7f39a01

Change-Id: I32e45a228f4249a06e0fa93667a47bc95e3878b2
This commit is contained in:
Jorim Jaggi
2019-06-11 08:31:23 -07:00
committed by android-build-merger

View File

@@ -540,6 +540,14 @@ class AppWindowToken extends WindowToken implements WindowManagerService.AppFree
// If the app was already visible, don't reset the waitingToShow state.
if (isHidden()) {
waitingToShow = true;
// Let's reset the draw state in order to prevent the starting window to be
// immediately dismissed when the app still has the surface.
forAllWindows(w -> {
if (w.mAttrs.type != TYPE_APPLICATION_STARTING) {
w.mWinAnimator.resetDrawState();
}
}, true /* traverseTopToBottom */);
}
}