summaryrefslogtreecommitdiffstats
path: root/src/com/android/settings/ButtonSettings.java
diff options
context:
space:
mode:
authorChristopher R. Palmer <crpalmer@gmail.com>2014-10-07 11:15:51 -0400
committerAdnan Begovic <adnan@cyngn.com>2015-10-29 17:36:27 -0700
commitd6c1ebc2485927b1711ac9c0bd93b798090066a0 (patch)
treec87179bc4c307e1c0d0e5fa84255d33c25f941ff /src/com/android/settings/ButtonSettings.java
parent016ae72ba5520ce573f1ccdf6861b5a5024d1d50 (diff)
downloadpackages_apps_Settings-d6c1ebc2485927b1711ac9c0bd93b798090066a0.zip
packages_apps_Settings-d6c1ebc2485927b1711ac9c0bd93b798090066a0.tar.gz
packages_apps_Settings-d6c1ebc2485927b1711ac9c0bd93b798090066a0.tar.bz2
setting: Always remove Left-handed mode setting for non-phones
Right now, this option is only removed if you have a navigation bar enabled and you aren't a phone. This leads to UI wonkiness on devices that allow the navigation bar to be toggled on/off: * Enable the navigation bar. * Navigate elsewhere and back to Buttons (force it to reload) * Settings >> Buttons now contains a (grayed out) Left-handed mode. * Enable the navigation bar. Now Left-handed mode is available as an option even though it shouldn't be. Change-Id: Ifb3cdd18a014edffaf8bc53c46fc3c2f7a681370
Diffstat (limited to 'src/com/android/settings/ButtonSettings.java')
-rw-r--r--src/com/android/settings/ButtonSettings.java10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/com/android/settings/ButtonSettings.java b/src/com/android/settings/ButtonSettings.java
index 4f5e9ea..f9ff330 100644
--- a/src/com/android/settings/ButtonSettings.java
+++ b/src/com/android/settings/ButtonSettings.java
@@ -313,11 +313,11 @@ public class ButtonSettings extends SettingsPreferenceFragment implements
boolean hasNavBar = WindowManagerGlobal.getWindowManagerService().hasNavigationBar()
|| forceNavbar;
- if (hasNavBar) {
- if (!Utils.isPhone(getActivity())) {
- mNavigationPreferencesCat.removePreference(mNavigationBarLeftPref);
- }
- } else if (needsNavigationBar || !isKeyDisablerSupported()) {
+ if (!Utils.isPhone(getActivity())) {
+ mNavigationPreferencesCat.removePreference(mNavigationBarLeftPref);
+ }
+
+ if (!hasNavBar && (needsNavigationBar || !isKeyDisablerSupported())) {
// Hide navigation bar category
prefScreen.removePreference(mNavigationPreferencesCat);
}