Update wallpaper requestedVisibility with all other visibility

All other visibility is handled during ensureACtivitiesVisible, so
update visibility of wallpaper at the same time.

Bug: 187461719
Test: launch a landscape-only activity from home screen, observe
wallpaper.

Change-Id: I428309607fd406ab821951cf9afbcbb7da27b098
This commit is contained in:
Evan Rosky
2021-12-02 21:05:42 -08:00
parent e44b5fe74d
commit 685d508c85

View File

@@ -5883,6 +5883,13 @@ class DisplayContent extends RootDisplayArea implements WindowManagerPolicy.Disp
rootTask.ensureActivitiesVisible(starting, configChanges, preserveWindows,
notifyClients);
});
if (mTransitionController.isCollecting()
&& mWallpaperController.getWallpaperTarget() != null) {
// Also update wallpapers so that their requestedVisibility immediately reflects
// the changes to activity visibility.
// TODO(b/206005136): Move visibleRequested logic up to WindowToken.
mWallpaperController.adjustWallpaperWindows();
}
} finally {
mAtmService.mTaskSupervisor.endActivityVisibilityUpdate();
mInEnsureActivitiesVisible = false;