Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit cd366177 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Automerger Merge Worker
Browse files

Merge "Enable the split-items from the overview panel" into tm-qpr-dev am: 89487c8a

parents dbafd00d 89487c8a
Loading
Loading
Loading
Loading
+9 −4
Original line number Original line Diff line number Diff line
@@ -16,6 +16,7 @@


package com.android.systemui.shared.recents.model;
package com.android.systemui.shared.recents.model;


import static android.app.WindowConfiguration.ACTIVITY_TYPE_UNDEFINED;
import static android.view.Display.DEFAULT_DISPLAY;
import static android.view.Display.DEFAULT_DISPLAY;


import static com.android.wm.shell.common.split.SplitScreenConstants.CONTROLLED_ACTIVITY_TYPES;
import static com.android.wm.shell.common.split.SplitScreenConstants.CONTROLLED_ACTIVITY_TYPES;
@@ -245,12 +246,16 @@ public class Task {
     */
     */
    public static Task from(TaskKey taskKey, TaskInfo taskInfo, boolean isLocked) {
    public static Task from(TaskKey taskKey, TaskInfo taskInfo, boolean isLocked) {
        ActivityManager.TaskDescription td = taskInfo.taskDescription;
        ActivityManager.TaskDescription td = taskInfo.taskDescription;
        // Also consider undefined activity type to include tasks in overview right after rebooting
        // the device.
        final boolean isDockable = taskInfo.supportsMultiWindow
                && ArrayUtils.contains(CONTROLLED_WINDOWING_MODES, taskInfo.getWindowingMode())
                && (taskInfo.getActivityType() == ACTIVITY_TYPE_UNDEFINED
                || ArrayUtils.contains(CONTROLLED_ACTIVITY_TYPES, taskInfo.getActivityType()));
        return new Task(taskKey,
        return new Task(taskKey,
                td != null ? td.getPrimaryColor() : 0,
                td != null ? td.getPrimaryColor() : 0,
                td != null ? td.getBackgroundColor() : 0, taskInfo.supportsMultiWindow
                td != null ? td.getBackgroundColor() : 0, isDockable , isLocked, td,
                && ArrayUtils.contains(CONTROLLED_ACTIVITY_TYPES, taskInfo.getActivityType())
                taskInfo.topActivity);
                && ArrayUtils.contains(CONTROLLED_WINDOWING_MODES, taskInfo.getWindowingMode()),
                isLocked, td, taskInfo.topActivity);
    }
    }


    public Task(TaskKey key) {
    public Task(TaskKey key) {