Merge "[Re-land] Implement two intents or shortcuts to active split" into udc-dev am: 433d215c88

Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/22545656

Change-Id: I81c0730ca2070186e8241f6be1fb16735826608a
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
Tony Huang
2023-04-12 07:10:09 +00:00
committed by Automerger Merge Worker
2 changed files with 10 additions and 8 deletions
@@ -621,14 +621,15 @@ public class SystemUiProxy implements ISystemUiProxy {
} }
} }
public void startIntents(PendingIntent pendingIntent1, Bundle options1, public void startIntents(PendingIntent pendingIntent1, @Nullable ShortcutInfo shortcutInfo1,
PendingIntent pendingIntent2, Bundle options2, Bundle options1, PendingIntent pendingIntent2, @Nullable ShortcutInfo shortcutInfo2,
@SplitConfigurationOptions.StagePosition int splitPosition, Bundle options2, @SplitConfigurationOptions.StagePosition int splitPosition,
float splitRatio, RemoteTransition remoteTransition, InstanceId instanceId) { float splitRatio, RemoteTransition remoteTransition, InstanceId instanceId) {
if (mSystemUiProxy != null) { if (mSystemUiProxy != null) {
try { try {
mSplitScreen.startIntents(pendingIntent1, options1, pendingIntent2, options2, mSplitScreen.startIntents(pendingIntent1, shortcutInfo1, options1, pendingIntent2,
splitPosition, splitRatio, remoteTransition, instanceId); shortcutInfo2, options2, splitPosition, splitRatio, remoteTransition,
instanceId);
} catch (RemoteException e) { } catch (RemoteException e) {
Log.w(TAG, "Failed call startIntents"); Log.w(TAG, "Failed call startIntents");
} }
@@ -309,9 +309,10 @@ public class SplitSelectStateController {
shellInstanceId); shellInstanceId);
} else { } else {
mSystemUiProxy.startIntents(getPendingIntent(intent1, mInitialUser), mSystemUiProxy.startIntents(getPendingIntent(intent1, mInitialUser),
options1.toBundle(), getPendingIntent(intent2, mSecondUser), getShortcutInfo(intent1, mInitialUser), options1.toBundle(),
null /* options2 */, stagePosition, splitRatio, remoteTransition, getPendingIntent(intent2, mSecondUser),
shellInstanceId); getShortcutInfo(intent2, mSecondUser), null /* options2 */,
stagePosition, splitRatio, remoteTransition, shellInstanceId);
} }
} else { } else {
final RemoteSplitLaunchAnimationRunner animationRunner = final RemoteSplitLaunchAnimationRunner animationRunner =