Merge "Fix NPE when deciding whether to defer task stack animation." into pi-dev

This commit is contained in:
Winson Chung
2018-04-24 16:39:07 +00:00
committed by Android (Google) Code Review

View File

@@ -1722,6 +1722,9 @@ public class TaskStack extends WindowContainer<Task> implements
return true;
}
final Task homeTask = homeStack.getTopChild();
if (homeTask == null) {
return true;
}
final AppWindowToken homeApp = homeTask.getTopVisibleAppToken();
if (!homeTask.isVisible() || homeApp == null) {
return true;