Allow dreams to redraw when device is rotated.

Dreams currently will close and recreate a Dream when the device
rotates. This causes a bug in the Dream state as the current activity
closes but the device does not exit a Dreaming state.

Bug: 235263108
Bug: 239510155
Test: atest DreamManagerServiceTests#testDreamNotFinishAfterRotation
Change-Id: I01d803fd501f71da016395ad24a1fe0f92200b26
This commit is contained in:
Victor Truong
2022-08-16 12:33:43 -04:00
parent e076854f74
commit 262ef7cf06

View File

@@ -1486,6 +1486,7 @@ public class ActivityTaskManagerService extends IActivityTaskManager.Stub {
a.colorMode = ActivityInfo.COLOR_MODE_DEFAULT;
a.flags |= ActivityInfo.FLAG_EXCLUDE_FROM_RECENTS;
a.resizeMode = RESIZE_MODE_UNRESIZEABLE;
a.configChanges = ActivityInfo.CONFIG_ORIENTATION;
final ActivityOptions options = ActivityOptions.makeBasic();
options.setLaunchActivityType(ACTIVITY_TYPE_DREAM);