From 1eade2f947cae931c2acc73b980b89ca77c7fe5d Mon Sep 17 00:00:00 2001 From: Sunny Goyal Date: Mon, 5 Aug 2019 11:23:19 -0700 Subject: [PATCH] Use task display id when starting split screen Before starting split screen animation, we dismiss the task view, which can detach the clicked view immediately, if animations are dissabled. That will cause NPE as view.getDisplay will be null Bug: 138793362 Change-Id: I611f6a824f756eceeed57aac5afdf38f421ff8d2 --- .../src/com/android/quickstep/TaskSystemShortcut.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/quickstep/recents_ui_overrides/src/com/android/quickstep/TaskSystemShortcut.java b/quickstep/recents_ui_overrides/src/com/android/quickstep/TaskSystemShortcut.java index 213c5d3244..fd45923070 100644 --- a/quickstep/recents_ui_overrides/src/com/android/quickstep/TaskSystemShortcut.java +++ b/quickstep/recents_ui_overrides/src/com/android/quickstep/TaskSystemShortcut.java @@ -207,8 +207,7 @@ public class TaskSystemShortcut extends SystemShortcut } }; WindowManagerWrapper.getInstance().overridePendingAppTransitionMultiThumbFuture( - future, animStartedListener, mHandler, true /* scaleUp */, - v.getDisplay().getDisplayId()); + future, animStartedListener, mHandler, true /* scaleUp */, displayId); } }); }