Notify draw for relaunch with preserved window

In case any logic depends on ActivityRecord#startRelaunching
~ WindowState#finishDrawing can receive paired invocation.

Bug: 264634241
Bug: 263066320
Test: An activity calls recreate().
      There will be a log "finishDrawing of relaunch: Window".
Change-Id: I9406ab5cbca5b3c9c407a136bf4fcb97111d78b8
(cherry picked from commit 5b49c7fbbf)
This commit is contained in:
Riddle Hsu
2023-01-06 13:28:46 +00:00
parent 958993bfe0
commit 1ab5329fd3

View File

@@ -1113,6 +1113,8 @@ public final class ViewRootImpl implements ViewParent,
// Update the last resource config in case the resource configuration was changed while
// activity relaunched.
updateLastConfigurationFromResources(getConfiguration());
// Make sure to report the completion of draw for relaunch with preserved window.
reportNextDraw("rebuilt");
}
private Configuration getConfiguration() {