Loading libs/WindowManager/Shell/src/com/android/wm/shell/recents/RecentsTransitionHandler.java +9 −2 Original line number Diff line number Diff line Loading @@ -21,6 +21,7 @@ import static android.app.WindowConfiguration.ACTIVITY_TYPE_HOME; import static android.app.WindowConfiguration.ACTIVITY_TYPE_RECENTS; import static android.app.WindowConfiguration.WINDOWING_MODE_FULLSCREEN; import static android.view.Display.DEFAULT_DISPLAY; import static android.view.Display.INVALID_DISPLAY; import static android.view.WindowManager.KEYGUARD_VISIBILITY_TRANSIT_FLAGS; import static android.view.WindowManager.TRANSIT_CHANGE; import static android.view.WindowManager.TRANSIT_CLOSE; Loading @@ -44,6 +45,7 @@ import static com.android.wm.shell.transition.Transitions.TRANSIT_START_RECENTS_ import android.annotation.Nullable; import android.annotation.SuppressLint; import android.app.ActivityManager; import android.app.ActivityOptions; import android.app.ActivityTaskManager; import android.app.IApplicationThread; import android.app.PendingIntent; Loading Loading @@ -237,8 +239,13 @@ public class RecentsTransitionHandler implements Transitions.TransitionHandler, // requires the handler, but the mixed handler also needs a reference to the transition. RecentsMixedHandler mixer = null; Consumer<IBinder> setTransitionForMixer = null; ActivityOptions activityOptions = ActivityOptions.fromBundle(options); int displayId = activityOptions.getLaunchDisplayId(); if (displayId == INVALID_DISPLAY) { displayId = DEFAULT_DISPLAY; } for (int i = 0; i < mMixers.size(); ++i) { setTransitionForMixer = mMixers.get(i).handleRecentsRequest(); setTransitionForMixer = mMixers.get(i).handleRecentsRequest(displayId); if (setTransitionForMixer != null) { mixer = mMixers.get(i); break; Loading Loading @@ -1807,7 +1814,7 @@ public class RecentsTransitionHandler implements Transitions.TransitionHandler, * {@link #mergeAnimation}, and {@link #onTransitionConsumed} methods. */ @Nullable Consumer<IBinder> handleRecentsRequest(); Consumer<IBinder> handleRecentsRequest(int displayId); /** * Called when a recents transition has finished, with a WCT and SurfaceControl Transaction Loading libs/WindowManager/Shell/src/com/android/wm/shell/transition/DefaultMixedHandler.java +7 −4 Original line number Diff line number Diff line Loading @@ -19,7 +19,6 @@ package com.android.wm.shell.transition; import static android.app.WindowConfiguration.ACTIVITY_TYPE_HOME; import static android.app.WindowConfiguration.ACTIVITY_TYPE_RECENTS; import static android.app.WindowConfiguration.WINDOWING_MODE_FULLSCREEN; import static android.view.Display.DEFAULT_DISPLAY; import static android.view.WindowManager.TRANSIT_CHANGE; import static android.view.WindowManager.TRANSIT_PIP; import static android.window.TransitionInfo.FLAG_IN_TASK_WITH_EMBEDDED_ACTIVITY; Loading Loading @@ -467,7 +466,12 @@ public class DefaultMixedHandler implements MixedTransitionHandler, } @Override public Consumer<IBinder> handleRecentsRequest() { public Consumer<IBinder> handleRecentsRequest(int displayId) { ProtoLog.v(ShellProtoLogGroup.WM_SHELL_TRANSITIONS, " handleRecentsRequest displayId=%d deskActive=%b", displayId, mDesktopTasksController != null && mDesktopTasksController.isAnyDeskActive( displayId)); if (mRecentsHandler != null) { if (mSplitHandler.isSplitScreenVisible()) { return this::setRecentsTransitionDuringSplit; Loading @@ -475,8 +479,7 @@ public class DefaultMixedHandler implements MixedTransitionHandler, && !mKeyguardHandler.isKeyguardAnimating()) { return this::setRecentsTransitionDuringKeyguard; } else if (mDesktopTasksController != null // Check on the default display. Recents/gesture nav is only available there && mDesktopTasksController.isAnyDeskActive(DEFAULT_DISPLAY)) { && mDesktopTasksController.isAnyDeskActive(displayId)) { return this::setRecentsTransitionDuringDesktop; } } Loading Loading
libs/WindowManager/Shell/src/com/android/wm/shell/recents/RecentsTransitionHandler.java +9 −2 Original line number Diff line number Diff line Loading @@ -21,6 +21,7 @@ import static android.app.WindowConfiguration.ACTIVITY_TYPE_HOME; import static android.app.WindowConfiguration.ACTIVITY_TYPE_RECENTS; import static android.app.WindowConfiguration.WINDOWING_MODE_FULLSCREEN; import static android.view.Display.DEFAULT_DISPLAY; import static android.view.Display.INVALID_DISPLAY; import static android.view.WindowManager.KEYGUARD_VISIBILITY_TRANSIT_FLAGS; import static android.view.WindowManager.TRANSIT_CHANGE; import static android.view.WindowManager.TRANSIT_CLOSE; Loading @@ -44,6 +45,7 @@ import static com.android.wm.shell.transition.Transitions.TRANSIT_START_RECENTS_ import android.annotation.Nullable; import android.annotation.SuppressLint; import android.app.ActivityManager; import android.app.ActivityOptions; import android.app.ActivityTaskManager; import android.app.IApplicationThread; import android.app.PendingIntent; Loading Loading @@ -237,8 +239,13 @@ public class RecentsTransitionHandler implements Transitions.TransitionHandler, // requires the handler, but the mixed handler also needs a reference to the transition. RecentsMixedHandler mixer = null; Consumer<IBinder> setTransitionForMixer = null; ActivityOptions activityOptions = ActivityOptions.fromBundle(options); int displayId = activityOptions.getLaunchDisplayId(); if (displayId == INVALID_DISPLAY) { displayId = DEFAULT_DISPLAY; } for (int i = 0; i < mMixers.size(); ++i) { setTransitionForMixer = mMixers.get(i).handleRecentsRequest(); setTransitionForMixer = mMixers.get(i).handleRecentsRequest(displayId); if (setTransitionForMixer != null) { mixer = mMixers.get(i); break; Loading Loading @@ -1807,7 +1814,7 @@ public class RecentsTransitionHandler implements Transitions.TransitionHandler, * {@link #mergeAnimation}, and {@link #onTransitionConsumed} methods. */ @Nullable Consumer<IBinder> handleRecentsRequest(); Consumer<IBinder> handleRecentsRequest(int displayId); /** * Called when a recents transition has finished, with a WCT and SurfaceControl Transaction Loading
libs/WindowManager/Shell/src/com/android/wm/shell/transition/DefaultMixedHandler.java +7 −4 Original line number Diff line number Diff line Loading @@ -19,7 +19,6 @@ package com.android.wm.shell.transition; import static android.app.WindowConfiguration.ACTIVITY_TYPE_HOME; import static android.app.WindowConfiguration.ACTIVITY_TYPE_RECENTS; import static android.app.WindowConfiguration.WINDOWING_MODE_FULLSCREEN; import static android.view.Display.DEFAULT_DISPLAY; import static android.view.WindowManager.TRANSIT_CHANGE; import static android.view.WindowManager.TRANSIT_PIP; import static android.window.TransitionInfo.FLAG_IN_TASK_WITH_EMBEDDED_ACTIVITY; Loading Loading @@ -467,7 +466,12 @@ public class DefaultMixedHandler implements MixedTransitionHandler, } @Override public Consumer<IBinder> handleRecentsRequest() { public Consumer<IBinder> handleRecentsRequest(int displayId) { ProtoLog.v(ShellProtoLogGroup.WM_SHELL_TRANSITIONS, " handleRecentsRequest displayId=%d deskActive=%b", displayId, mDesktopTasksController != null && mDesktopTasksController.isAnyDeskActive( displayId)); if (mRecentsHandler != null) { if (mSplitHandler.isSplitScreenVisible()) { return this::setRecentsTransitionDuringSplit; Loading @@ -475,8 +479,7 @@ public class DefaultMixedHandler implements MixedTransitionHandler, && !mKeyguardHandler.isKeyguardAnimating()) { return this::setRecentsTransitionDuringKeyguard; } else if (mDesktopTasksController != null // Check on the default display. Recents/gesture nav is only available there && mDesktopTasksController.isAnyDeskActive(DEFAULT_DISPLAY)) { && mDesktopTasksController.isAnyDeskActive(displayId)) { return this::setRecentsTransitionDuringDesktop; } } Loading