Hardware key: Enable single tap rebinding for hwkey back and home

Initially, this policy was put in place to safeguard
the UX by preventing a usecase where the device could
be put in a state without back or home available. However,
if a user puts the device in this state, it is easy enough
to navigate to button settings to fix it

Change-Id: I6b71f9e54fcb99356e07f236e9ed926ac5fc017e
Signed-off-by: mhkjahromi <m.h.k.jahromi@gmail.com>
Signed-off-by: SagarMakhar <sagarmakhar@gmail.com>
Signed-off-by: Hưng Phan <phandinhhungvp2001@gmail.com>
This commit is contained in:
GodfatherX64
2016-06-15 12:51:05 +02:00
committed by Hưng Phan
parent 7aa0587205
commit db80cf7f2f
2 changed files with 17 additions and 0 deletions

View File

@@ -46,6 +46,12 @@
<PreferenceCategory
android:key="back_key"
android:title="@string/hardware_keys_back_key_title" >
<com.cherish.settings.preferences.ActionPreference
android:key="hwkeys_button_back_single_tap"
android:summary="@string/hardware_keys_single_tap_summary"
android:title="@string/hardware_keys_single_tap_title" >
</com.cherish.settings.preferences.ActionPreference>
<com.cherish.settings.preferences.ActionPreference
android:key="hwkeys_button_back_long_press"
@@ -64,6 +70,12 @@
<PreferenceCategory
android:key="home_key"
android:title="@string/hardware_keys_home_key_title" >
<com.cherish.settings.preferences.ActionPreference
android:key="hwkeys_button_home_single_tap"
android:summary="@string/hardware_keys_single_tap_summary"
android:title="@string/hardware_keys_single_tap_title" >
</com.cherish.settings.preferences.ActionPreference>
<com.cherish.settings.preferences.ActionPreference
android:key="hwkeys_button_home_long_press"

View File

@@ -154,6 +154,11 @@ public class ButtonSettings extends ActionFragment implements OnPreferenceChange
return MetricsProto.MetricsEvent.CHERISH_SETTINGS;
}
@Override
protected boolean usesExtendedActionsList() {
return true;
}
/**
* For Search.
*/