From d460c084eb4751436e7ebd9c3025defca7b236a3 Mon Sep 17 00:00:00 2001 From: Mario Bertschler Date: Wed, 16 May 2018 10:39:42 +0200 Subject: [PATCH] Fixes a crash when turning off workprofile while the workprofile tab is active. Bug: 79735930 Change-Id: Iafaddf827e648c9d39df78393a96f90dfc86fcca --- src/com/android/launcher3/allapps/FloatingHeaderView.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/com/android/launcher3/allapps/FloatingHeaderView.java b/src/com/android/launcher3/allapps/FloatingHeaderView.java index 5a66ccd386..462e7f34e1 100644 --- a/src/com/android/launcher3/allapps/FloatingHeaderView.java +++ b/src/com/android/launcher3/allapps/FloatingHeaderView.java @@ -96,7 +96,7 @@ public class FloatingHeaderView extends LinearLayout implements mMainRV = setupRV(mMainRV, mAH[AllAppsContainerView.AdapterHolder.MAIN].recyclerView); mWorkRV = setupRV(mWorkRV, mAH[AllAppsContainerView.AdapterHolder.WORK].recyclerView); mParent = (ViewGroup) mMainRV.getParent(); - setMainActive(mMainRVActive); + setMainActive(mMainRVActive || mWorkRV == null); reset(false); }