From 074c4344f5f32a6c92ec1736cf0132242da11a21 Mon Sep 17 00:00:00 2001 From: Winson Chung Date: Mon, 26 Mar 2018 17:27:19 -0700 Subject: [PATCH] Disable long press recents whenever overview service is bound - In both the quickstep and fallback cases, we'll rely on the UI to enter split screen and not long press recents button. Bug: 76438197 Test: Manual, long press recents with fallback activity, ensure nothing happens Change-Id: If3f367632c5c9ffae520285c694c71054b02f209 --- .../systemui/statusbar/phone/NavigationBarFragment.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarFragment.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarFragment.java index 09f0cf5d5ec0d..58f8baa6ef5be 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarFragment.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarFragment.java @@ -926,7 +926,9 @@ public class NavigationBarFragment extends Fragment implements Callbacks { private boolean onLongPressRecents() { if (mRecents == null || !ActivityManager.supportsMultiWindow(getContext()) || !mDivider.getView().getSnapAlgorithm().isSplitScreenFeasible() - || Recents.getConfiguration().isLowRamDevice) { + || Recents.getConfiguration().isLowRamDevice + // If we are connected to the overview service, then disable the recents button + || mOverviewProxyService.getProxy() != null) { return false; }