From f3918002f3f6283009b9b5b6afcc8a9ffb706171 Mon Sep 17 00:00:00 2001 From: Winson Date: Tue, 12 Jan 2016 15:59:29 -0800 Subject: [PATCH] Fixing issue with checking the docked stack state for the wrong user. Bug: 26256285 Change-Id: I068ee8250dc75bda984092300d75031422fbbd11 --- .../src/com/android/systemui/recents/misc/SystemServicesProxy.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/packages/SystemUI/src/com/android/systemui/recents/misc/SystemServicesProxy.java b/packages/SystemUI/src/com/android/systemui/recents/misc/SystemServicesProxy.java index e05a6f8f504f..01de60c5724e 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/misc/SystemServicesProxy.java +++ b/packages/SystemUI/src/com/android/systemui/recents/misc/SystemServicesProxy.java @@ -367,7 +367,7 @@ public class SystemServicesProxy { } /** - * @return whether there are any docked tasks. + * @return whether there are any docked tasks for the current user. */ public boolean hasDockedTask() { if (mIam == null) return false; @@ -375,6 +375,9 @@ public class SystemServicesProxy { ActivityManager.StackInfo stackInfo = null; try { stackInfo = mIam.getStackInfo(DOCKED_STACK_ID); + if (stackInfo != null && stackInfo.userId != getCurrentUser()) { + return false; + } } catch (RemoteException e) { e.printStackTrace(); } -- 2.11.0