Merge "Create TaskOperations when shell transition is off" into tm-qpr-dev

This commit is contained in:
Garfield Tan
2023-01-31 23:51:40 +00:00
committed by Android (Google) Code Review
2 changed files with 6 additions and 1 deletions

View File

@@ -36,6 +36,7 @@ import com.android.wm.shell.ShellTaskOrganizer;
import com.android.wm.shell.common.DisplayController;
import com.android.wm.shell.common.SyncTransactionQueue;
import com.android.wm.shell.freeform.FreeformTaskTransitionStarter;
import com.android.wm.shell.transition.Transitions;
/**
* View model for the window decoration with a caption and shadows. Works with
@@ -65,6 +66,9 @@ public class CaptionWindowDecorViewModel implements WindowDecorViewModel {
mTaskOrganizer = taskOrganizer;
mDisplayController = displayController;
mSyncQueue = syncQueue;
if (!Transitions.ENABLE_SHELL_TRANSITIONS) {
mTaskOperations = new TaskOperations(null, mContext, mSyncQueue);
}
}
@Override

View File

@@ -29,7 +29,8 @@ import com.android.wm.shell.freeform.FreeformTaskTransitionStarter;
*/
public interface WindowDecorViewModel {
/**
* Sets the transition starter that starts freeform task transitions.
* Sets the transition starter that starts freeform task transitions. Only called when
* {@link com.android.wm.shell.transition.Transitions#ENABLE_SHELL_TRANSITIONS} is {@code true}.
*
* @param transitionStarter the transition starter that starts freeform task transitions
*/