Disallow enter PiP when starting a split task

Disallow enter PiP while Launching another task
into one of split stage tasks.

This should also help Core keep
ActivityTaskSupervisor#mUserLeaving as false,
which helps avoid onUserLeaveHint() on client-side
and any legacy enter-PiP requests.

Bug: 336477473
Test: repro the steps in the bug (latest comments)

Change-Id: Idceebc9742f45d17ebe5398df2c151085d33c775
diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/splitscreen/StageCoordinator.java b/libs/WindowManager/Shell/src/com/android/wm/shell/splitscreen/StageCoordinator.java
index cc995ea..a5fc347 100644
--- a/libs/WindowManager/Shell/src/com/android/wm/shell/splitscreen/StageCoordinator.java
+++ b/libs/WindowManager/Shell/src/com/android/wm/shell/splitscreen/StageCoordinator.java
@@ -1893,6 +1893,10 @@
         // will be canceled.
         options.setPendingIntentBackgroundActivityStartMode(MODE_BACKGROUND_ACTIVITY_START_ALLOWED);
         options.setPendingIntentBackgroundActivityLaunchAllowedByPermission(true);
+
+        // TODO (b/336477473): Disallow enter PiP when launching a task in split by default;
+        //                     this might have to be changed as more split-to-pip cujs are defined.
+        options.setDisallowEnterPictureInPictureWhileLaunching(true);
         opts.putAll(options.toBundle());
     }