Loading res/values/strings.xml +2 −0 Original line number Diff line number Diff line Loading @@ -213,6 +213,8 @@ <string name="home_answer_call_summary">Answer incoming calls by pressing the home button</string> <string name="extras_title">Extras</string> <string name="additional_buttons_title">Additional buttons</string> <string name="click_partial_screenshot_title">Click to partial screenshot</string> <string name="click_partial_screenshot_summary">Short click Volume Down and Power to take partial screenshot</string> <!-- Key backlight --> <string name="button_backlight_title">Backlight</string> Loading res/xml/button_settings.xml +6 −0 Original line number Diff line number Diff line Loading @@ -314,6 +314,12 @@ android:action="org.lineageos.settings.device.ADDITIONAL_BUTTONS_SETTINGS" /> </lineageos.preference.RemotePreference> <lineageos.preference.LineageSystemSettingSwitchPreference android:key="click_partial_screenshot" android:title="@string/click_partial_screenshot_title" android:summary="@string/click_partial_screenshot_summary" android:defaultValue="false" /> </PreferenceCategory> </PreferenceScreen> src/org/lineageos/lineageparts/input/ButtonSettings.java +6 −0 Original line number Diff line number Diff line Loading @@ -99,6 +99,8 @@ public class ButtonSettings extends SettingsPreferenceFragment "torch_long_press_power_gesture"; private static final String KEY_TORCH_LONG_PRESS_POWER_TIMEOUT = "torch_long_press_power_timeout"; private static final String KEY_CLICK_PARTIAL_SCREENSHOT = "click_partial_screenshot"; private static final String CATEGORY_POWER = "power_key"; private static final String CATEGORY_HOME = "home_key"; Loading @@ -110,6 +112,7 @@ public class ButtonSettings extends SettingsPreferenceFragment private static final String CATEGORY_VOLUME = "volume_keys"; private static final String CATEGORY_BACKLIGHT = "key_backlight"; private static final String CATEGORY_NAVBAR = "navigation_bar_category"; private static final String CATEGORY_EXTRAS = "extras_category"; private ListPreference mHomeLongPressAction; private ListPreference mHomeDoubleTapAction; Loading Loading @@ -178,6 +181,7 @@ public class ButtonSettings extends SettingsPreferenceFragment final PreferenceCategory appSwitchCategory = prefScreen.findPreference(CATEGORY_APPSWITCH); final PreferenceCategory volumeCategory = prefScreen.findPreference(CATEGORY_VOLUME); final PreferenceCategory cameraCategory = prefScreen.findPreference(CATEGORY_CAMERA); final PreferenceCategory extrasCategory = prefScreen.findPreference(CATEGORY_EXTRAS); // Power button ends calls. mPowerEndCall = findPreference(KEY_POWER_END_CALL); Loading Loading @@ -389,6 +393,7 @@ public class ButtonSettings extends SettingsPreferenceFragment } } else { prefScreen.removePreference(volumeCategory); extrasCategory.removePreference(findPreference(KEY_CLICK_PARTIAL_SCREENSHOT)); } // Only show the navigation bar category on devices that have a navigation bar Loading Loading @@ -828,6 +833,7 @@ public class ButtonSettings extends SettingsPreferenceFragment result.add(KEY_VOLUME_MUSIC_CONTROLS); result.add(KEY_VOLUME_PANEL_ON_LEFT); result.add(KEY_VOLUME_WAKE_SCREEN); result.add(KEY_CLICK_PARTIAL_SCREENSHOT); } else if (!DeviceUtils.canWakeUsingVolumeKeys(context)) { result.add(KEY_VOLUME_WAKE_SCREEN); } Loading Loading
res/values/strings.xml +2 −0 Original line number Diff line number Diff line Loading @@ -213,6 +213,8 @@ <string name="home_answer_call_summary">Answer incoming calls by pressing the home button</string> <string name="extras_title">Extras</string> <string name="additional_buttons_title">Additional buttons</string> <string name="click_partial_screenshot_title">Click to partial screenshot</string> <string name="click_partial_screenshot_summary">Short click Volume Down and Power to take partial screenshot</string> <!-- Key backlight --> <string name="button_backlight_title">Backlight</string> Loading
res/xml/button_settings.xml +6 −0 Original line number Diff line number Diff line Loading @@ -314,6 +314,12 @@ android:action="org.lineageos.settings.device.ADDITIONAL_BUTTONS_SETTINGS" /> </lineageos.preference.RemotePreference> <lineageos.preference.LineageSystemSettingSwitchPreference android:key="click_partial_screenshot" android:title="@string/click_partial_screenshot_title" android:summary="@string/click_partial_screenshot_summary" android:defaultValue="false" /> </PreferenceCategory> </PreferenceScreen>
src/org/lineageos/lineageparts/input/ButtonSettings.java +6 −0 Original line number Diff line number Diff line Loading @@ -99,6 +99,8 @@ public class ButtonSettings extends SettingsPreferenceFragment "torch_long_press_power_gesture"; private static final String KEY_TORCH_LONG_PRESS_POWER_TIMEOUT = "torch_long_press_power_timeout"; private static final String KEY_CLICK_PARTIAL_SCREENSHOT = "click_partial_screenshot"; private static final String CATEGORY_POWER = "power_key"; private static final String CATEGORY_HOME = "home_key"; Loading @@ -110,6 +112,7 @@ public class ButtonSettings extends SettingsPreferenceFragment private static final String CATEGORY_VOLUME = "volume_keys"; private static final String CATEGORY_BACKLIGHT = "key_backlight"; private static final String CATEGORY_NAVBAR = "navigation_bar_category"; private static final String CATEGORY_EXTRAS = "extras_category"; private ListPreference mHomeLongPressAction; private ListPreference mHomeDoubleTapAction; Loading Loading @@ -178,6 +181,7 @@ public class ButtonSettings extends SettingsPreferenceFragment final PreferenceCategory appSwitchCategory = prefScreen.findPreference(CATEGORY_APPSWITCH); final PreferenceCategory volumeCategory = prefScreen.findPreference(CATEGORY_VOLUME); final PreferenceCategory cameraCategory = prefScreen.findPreference(CATEGORY_CAMERA); final PreferenceCategory extrasCategory = prefScreen.findPreference(CATEGORY_EXTRAS); // Power button ends calls. mPowerEndCall = findPreference(KEY_POWER_END_CALL); Loading Loading @@ -389,6 +393,7 @@ public class ButtonSettings extends SettingsPreferenceFragment } } else { prefScreen.removePreference(volumeCategory); extrasCategory.removePreference(findPreference(KEY_CLICK_PARTIAL_SCREENSHOT)); } // Only show the navigation bar category on devices that have a navigation bar Loading Loading @@ -828,6 +833,7 @@ public class ButtonSettings extends SettingsPreferenceFragment result.add(KEY_VOLUME_MUSIC_CONTROLS); result.add(KEY_VOLUME_PANEL_ON_LEFT); result.add(KEY_VOLUME_WAKE_SCREEN); result.add(KEY_CLICK_PARTIAL_SCREENSHOT); } else if (!DeviceUtils.canWakeUsingVolumeKeys(context)) { result.add(KEY_VOLUME_WAKE_SCREEN); } Loading