summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Sunny Goyal <sunnygoyal@google.com> 2019-08-09 15:18:28 -0700
committer android-build-merger <android-build-merger@google.com> 2019-08-09 15:18:28 -0700
commitffe8886cd306200189e4ac066c1c4a224d628dfd (patch)
treea0b64cc1e51257771639049d47995071440b6081
parent3fa31fb1cf12f88484defd4e9b2a471f84ef1f37 (diff)
parent2862d538b6dfd6ae4b1c5d6be7bdd106b05fd556 (diff)
Merge "Hide the home handle in lock task home when home and overview are disabled" into qt-r1-dev
am: 2862d538b6 Change-Id: Ied33a36a262ad766421321e9f4c53bb07a608fe7
-rw-r--r--packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarView.java5
1 files changed, 5 insertions, 0 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarView.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarView.java
index 6bfa048eb63d..f689a3eadf58 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarView.java
@@ -619,6 +619,10 @@ public class NavigationBarView extends FrameLayout implements
// Always disable recents when alternate car mode UI is active and for secondary displays.
boolean disableRecent = isRecentsButtonDisabled();
+ // Disable the home handle if both hone and recents are disabled
+ boolean disableHomeHandle = disableRecent
+ && ((mDisabledFlags & View.STATUS_BAR_DISABLE_HOME) != 0);
+
boolean disableBack = !useAltBack && (isGesturalMode(mNavBarMode)
|| ((mDisabledFlags & View.STATUS_BAR_DISABLE_BACK) != 0));
@@ -649,6 +653,7 @@ public class NavigationBarView extends FrameLayout implements
getBackButton().setVisibility(disableBack ? View.INVISIBLE : View.VISIBLE);
getHomeButton().setVisibility(disableHome ? View.INVISIBLE : View.VISIBLE);
getRecentsButton().setVisibility(disableRecent ? View.INVISIBLE : View.VISIBLE);
+ getHomeHandle().setVisibility(disableHomeHandle ? View.INVISIBLE : View.VISIBLE);
}
@VisibleForTesting