Add ability to show wallpaper during animation

In the new task switch animations, we'd like to show the wallpaper
behind. For that, we add the ability to show the wallpaper for
any animation via Animation.showWallpaper as an XML attribute.

If the window of an app is animating, and the animation requests
the wallpaper, it can also be a wallpaper.

One remaning issue here is that we don't wait for the wallpaper
to be drawn when waiting for the transition. However, usually this
isn't an issue because the wallpaper is drawn in any case.

To fix this we'd need to load the animation already and then make
it a target before the animation starts, which is a bit involved
/quirky.

Test: Open/close task, observe wallpaper behind
Test: go/wm-smoke
Bug: 72396815
Change-Id: I676273a4e6627f8b5e0a1366fcd80a7c92018123
diff --git a/services/core/java/com/android/server/wm/RootWindowContainer.java b/services/core/java/com/android/server/wm/RootWindowContainer.java
index a4f20b01..6356a35 100644
--- a/services/core/java/com/android/server/wm/RootWindowContainer.java
+++ b/services/core/java/com/android/server/wm/RootWindowContainer.java
@@ -606,8 +606,11 @@
         // If we are ready to perform an app transition, check through all of the app tokens to be
         // shown and see if they are ready to go.
         if (mService.mAppTransition.isReady()) {
-            defaultDisplay.pendingLayoutChanges |=
-                    surfacePlacer.handleAppTransitionReadyLocked();
+            // This needs to be split into two expressions, as handleAppTransitionReadyLocked may
+            // modify dc.pendingLayoutChanges, which would get lost when writing
+            // defaultDisplay.pendingLayoutChanges |= handleAppTransitionReadyLocked()
+            final int layoutChanges = surfacePlacer.handleAppTransitionReadyLocked();
+            defaultDisplay.pendingLayoutChanges |= layoutChanges;
             if (DEBUG_LAYOUT_REPEATS)
                 surfacePlacer.debugLayoutRepeats("after handleAppTransitionReadyLocked",
                         defaultDisplay.pendingLayoutChanges);