Android9.0 SystemUI 最近任务出现重复的任务栈

Android9.0 Android10.0 SystemUI 最近任务出现重复的任务栈

解决办法:
frameworks/base/services/core/java/com/android/server/wm/RecentTasks.java
将 /RecentTasks.java 的 hasCompatibleActivityTypeAndWindowingMode 方法中的

    /**
     * @return Whether the activity types and windowing modes of the two tasks are considered
     *         compatible. This is necessary because we currently don't persist the activity type
     *         or the windowing mode with the task, so they can be undefined when restored.
     */
    private boolean hasCompatibleActivityTypeAndWindowingMode(TaskRecord t1, TaskRecord t2) {
		// ...
		// return isCompatibleType && isCompatibleMode;
		// 修改为
		return isCompatibleType;
    }
posted @ 2022-03-12 22:04  xiaomodecnblogs  阅读(125)  评论(0)    收藏  举报