1
0
mirror of https://codeberg.org/Freeyourgadget/Gadgetbridge synced 2024-12-26 10:35:50 +01:00

Replace old-style preference switch with Material 3 switch

This commit is contained in:
Arjan Schrijver 2023-10-06 22:06:35 +02:00
parent 9caab24c39
commit 69fcec059d
105 changed files with 287 additions and 265 deletions

View File

@ -29,7 +29,7 @@ import androidx.preference.PreferenceFragmentCompat;
import androidx.preference.PreferenceGroup;
import androidx.preference.PreferenceScreen;
import androidx.preference.SeekBarPreference;
import androidx.preference.SwitchPreference;
import androidx.preference.SwitchPreferenceCompat;
import com.mobeta.android.dslv.DragSortListPreference;
import com.mobeta.android.dslv.DragSortListPreferenceFragment;
@ -183,8 +183,8 @@ public abstract class AbstractPreferenceFragment extends PreferenceFragmentCompa
if (preference instanceof SeekBarPreference) {
final SeekBarPreference seekBarPreference = (SeekBarPreference) preference;
seekBarPreference.setValue(prefs.getInt(key, seekBarPreference.getValue()));
} else if (preference instanceof SwitchPreference) {
final SwitchPreference switchPreference = (SwitchPreference) preference;
} else if (preference instanceof SwitchPreferenceCompat) {
final SwitchPreferenceCompat switchPreference = (SwitchPreferenceCompat) preference;
switchPreference.setChecked(prefs.getBoolean(key, switchPreference.isChecked()));
} else if (preference instanceof ListPreference) {
final ListPreference listPreference = (ListPreference) preference;

View File

@ -28,7 +28,7 @@ import android.content.Context;
import androidx.preference.ListPreference;
import androidx.preference.Preference;
import androidx.preference.SwitchPreference;
import androidx.preference.SwitchPreferenceCompat;
import java.util.List;
@ -109,9 +109,9 @@ public class HeartRateCapability {
heartrateMeasurementInterval.setEntries(entries);
heartrateMeasurementInterval.setEntryValues(values);
final SwitchPreference activityMonitoring = handler.findPreference(PREF_HEARTRATE_ACTIVITY_MONITORING);
final SwitchPreference heartrateAlertEnabled = handler.findPreference(PREF_HEARTRATE_ALERT_ENABLED);
final SwitchPreference stressMonitoring = handler.findPreference(PREF_HEARTRATE_STRESS_MONITORING);
final SwitchPreferenceCompat activityMonitoring = handler.findPreference(PREF_HEARTRATE_ACTIVITY_MONITORING);
final SwitchPreferenceCompat heartrateAlertEnabled = handler.findPreference(PREF_HEARTRATE_ALERT_ENABLED);
final SwitchPreferenceCompat stressMonitoring = handler.findPreference(PREF_HEARTRATE_STRESS_MONITORING);
heartrateMeasurementInterval.setOnPreferenceChangeListener(new Preference.OnPreferenceChangeListener() {
public boolean onPreferenceChange(final Preference preference, final Object newVal) {

View File

@ -25,7 +25,7 @@ import androidx.preference.EditTextPreference;
import androidx.preference.ListPreference;
import androidx.preference.Preference;
import androidx.preference.PreferenceFragmentCompat;
import androidx.preference.SwitchPreference;
import androidx.preference.SwitchPreferenceCompat;
import nodomain.freeyourgadget.gadgetbridge.R;
import nodomain.freeyourgadget.gadgetbridge.activities.AbstractPreferenceFragment;
@ -99,7 +99,7 @@ public class HybridHRWatchfaceSettingsActivity extends AbstractSettingsActivityV
refresh_partial.setSummary(Integer.toString(settings.getDisplayTimeoutPartial()));
setInputTypeFor("pref_hybridhr_watchface_refresh_partial", InputType.TYPE_CLASS_NUMBER);
SwitchPreference wrist_flick_relative = findPreference("pref_hybridhr_watchface_wrist_flick_relative");
SwitchPreferenceCompat wrist_flick_relative = findPreference("pref_hybridhr_watchface_wrist_flick_relative");
wrist_flick_relative.setOnPreferenceChangeListener(this);
wrist_flick_relative.setChecked(settings.isWristFlickHandsMoveRelative());
@ -136,15 +136,15 @@ public class HybridHRWatchfaceSettingsActivity extends AbstractSettingsActivityV
move_hands.setValue(settings.getMoveHandsEvent());
move_hands.setSummary(move_hands.getEntry());
SwitchPreference power_saving_display = findPreference("pref_hybridhr_watchface_power_saving_display");
SwitchPreferenceCompat power_saving_display = findPreference("pref_hybridhr_watchface_power_saving_display");
power_saving_display.setOnPreferenceChangeListener(this);
power_saving_display.setChecked(settings.getPowersaveDisplay());
SwitchPreference power_saving_hands = findPreference("pref_hybridhr_watchface_power_saving_hands");
SwitchPreferenceCompat power_saving_hands = findPreference("pref_hybridhr_watchface_power_saving_hands");
power_saving_hands.setOnPreferenceChangeListener(this);
power_saving_hands.setChecked(settings.getPowersaveHands());
SwitchPreference light_up_on_notification = findPreference("pref_hybridhr_watchface_light_up_on_notification");
SwitchPreferenceCompat light_up_on_notification = findPreference("pref_hybridhr_watchface_light_up_on_notification");
light_up_on_notification.setOnPreferenceChangeListener(this);
light_up_on_notification.setChecked(settings.getLightUpOnNotification());
}

View File

@ -26,7 +26,7 @@ import androidx.preference.ListPreference;
import androidx.preference.Preference;
import androidx.preference.PreferenceCategory;
import androidx.preference.PreferenceFragmentCompat;
import androidx.preference.SwitchPreference;
import androidx.preference.SwitchPreferenceCompat;
import java.util.LinkedHashMap;
import java.util.TimeZone;
@ -173,11 +173,11 @@ public class HybridHRWatchfaceWidgetActivity extends AbstractSettingsActivityV2
customWidgetTimeout.setSummary(Integer.toString(widget.getExtraConfigInt("update_timeout", WIDGET_CUSTOM_DEFAULT_TIMEOUT)));
setInputTypeFor("pref_hybridhr_widget_custom_timeout", InputType.TYPE_CLASS_NUMBER);
SwitchPreference customWidgetHideText = findPreference("pref_hybridhr_widget_custom_hide_text");
SwitchPreferenceCompat customWidgetHideText = findPreference("pref_hybridhr_widget_custom_hide_text");
customWidgetHideText.setOnPreferenceChangeListener(this);
customWidgetHideText.setChecked(widget.getExtraConfigBoolean("timeout_hide_text", WIDGET_CUSTOM_DEFAULT_HIDE_TEXT));
SwitchPreference customWidgetShowCircle = findPreference("pref_hybridhr_widget_custom_show_circle");
SwitchPreferenceCompat customWidgetShowCircle = findPreference("pref_hybridhr_widget_custom_show_circle");
customWidgetShowCircle.setOnPreferenceChangeListener(this);
customWidgetShowCircle.setChecked(widget.getExtraConfigBoolean("timeout_show_circle", WIDGET_CUSTOM_DEFAULT_SHOW_CIRCLE));
}

View File

@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Found on https://stackoverflow.com/a/73782598 -->
<!-- Derived from https://github.com/androidx/androidx/blob/8cb282cc/preference/preference/res/layout/preference_widget_switch_compat.xml -->
<com.google.android.material.materialswitch.MaterialSwitch xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/switchWidget"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:background="@null"
android:clickable="false"
android:focusable="false" />

View File

@ -18,6 +18,7 @@
<item name="drawerArrowStyle">@style/GadgetbridgeTheme.DrawerButtonStyle</item>
<item name="toolbarNavigationButtonStyle">@style/GadgetbridgeTheme.NavigationButtonStyle</item>
<item name="actionOverflowButtonStyle">@style/GadgetbridgeTheme.OverflowMenuButton</item>
<item name="preferenceTheme">@style/AppPreferenceThemeOverlay</item>
<item name="drawer_header_color">?attr/colorPrimaryDark</item>
<item name="drawer_title_color">@android:color/white</item>
@ -51,6 +52,7 @@
<item name="drawerArrowStyle">@style/GadgetbridgeTheme.DrawerButtonStyle</item>
<item name="toolbarNavigationButtonStyle">@style/GadgetbridgeTheme.NavigationButtonStyle</item>
<item name="actionOverflowButtonStyle">@style/GadgetbridgeTheme.OverflowMenuButton</item>
<item name="preferenceTheme">@style/AppPreferenceThemeOverlay</item>
<item name="drawer_header_color">?attr/colorPrimaryDark</item>
<item name="drawer_title_color">@android:color/white</item>
@ -84,6 +86,7 @@
<item name="actionmenu_icon_color">?attr/colorOnSurface</item>
<item name="alternate_row_background">?attr/colorSecondaryContainer</item>
<item name="sports_activity_summary_background">?attr/colorSurface</item>
<item name="preferenceTheme">@style/AppPreferenceThemeOverlay</item>
</style>
<style name="GadgetbridgeThemeDynamicDark" parent="Theme.Material3.DynamicColors.Dark">
<item name="actionBarStyle">@style/GadgetbridgeThemeDynamic.ActionBar</item>
@ -97,6 +100,7 @@
<item name="actionmenu_icon_color">?attr/colorOnSurface</item>
<item name="alternate_row_background">?attr/colorSecondaryContainer</item>
<item name="sports_activity_summary_background">?attr/colorSurface</item>
<item name="preferenceTheme">@style/AppPreferenceThemeOverlay</item>
</style>
<style name="GadgetbridgeThemeDynamicDarkAmoled" parent="GadgetbridgeThemeDynamicDark">
<item name="android:windowBackground">@android:color/black</item>
@ -160,4 +164,12 @@
<item name="android:navigationBarColor">@color/primarydark_dark</item>
<item name="android:windowBackground">@drawable/splash</item>
</style>
<!-- preferences screens -->
<style name="AppPreferenceThemeOverlay" parent="@style/PreferenceThemeOverlay">
<item name="switchPreferenceCompatStyle">@style/AppSwitchPreference</item>
</style>
<style name="AppSwitchPreference" parent="@style/Preference.SwitchPreferenceCompat.Material">
<item name="widgetLayout">@layout/preference_material_switch</item>
</style>
</resources>

View File

@ -24,7 +24,7 @@
app:iconSpaceReserved="false"
app:useSimpleSummaryProvider="true" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="chart_heartrate_color"
android:summaryOff="@string/pref_chart_heartrate_color_orange"
@ -32,13 +32,13 @@
android:title="@string/pref_title_chart_heartrate_color"
app:iconSpaceReserved="false" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:key="charts_allow_swipe"
android:title="@string/pref_title_charts_swipe"
app:iconSpaceReserved="false" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="chart_sleep_range_24h"
android:summaryOff="@string/pref_chart_sleep_rolling_24_off"
@ -46,13 +46,13 @@
android:title="@string/pref_title_chart_sleep_rolling_24_hour"
app:iconSpaceReserved="false" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:key="charts_show_average"
android:title="@string/pref_title_charts_average"
app:iconSpaceReserved="false" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="charts_range"
android:summaryOff="@string/pref_charts_range_off"
@ -60,7 +60,7 @@
android:title="@string/pref_title_charts_range"
app:iconSpaceReserved="false" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:key="charts_show_ongoing_activity"
android:title="@string/show_ongoing_activity"

View File

@ -28,7 +28,7 @@
android:key="always_on_display_end"
android:title="@string/mi2_prefs_do_not_disturb_end" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:key="always_on_display_follow_watchface"
android:title="@string/prefs_always_on_display_follow_watchface" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:icon="@drawable/ic_vibration"
android:key="pref_antilost_enabled"

View File

@ -10,12 +10,12 @@
<!-- workaround for missing toolbar -->
<PreferenceCategory android:title="@string/prefs_autoheartrate_summary" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="pref_autoheartrate_switch"
android:title="@string/prefs_autoheartrate_measurement" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:dependency="pref_autoheartrate_switch"
android:key="pref_autoheartrate_sleep"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_wb_sunny"
android:key="autolight"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_block"
android:key="autoremove_message"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:icon="@drawable/ic_done_all"
android:defaultValue="true"
android:key="autoremove_notifications"

View File

@ -3,7 +3,7 @@
<PreferenceCategory
android:key="pref_header_location"
android:title="@string/pref_header_location">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_gps_location"
android:key="banglejs_gps_update"
@ -17,7 +17,7 @@
android:key="banglejs_gps_update_interval"
android:summary="@string/pref_summary_banglejs_phone_gps_update_interval"
android:title="@string/pref_title_banglejs_phone_gps_update_interval" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:dependency="banglejs_gps_update"
android:icon="@drawable/ic_gps_location"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_settings_remote"
android:key="bt_connected_advertisement"

View File

@ -12,14 +12,14 @@
public static final String PREF_BUTTON_ACTION_PRESS_DELAY = "button_action_press_count_delay";
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_smart_button"
android:key="button_action_enable"
android:summary="@string/mi2_prefs_button_action_summary"
android:title="@string/mi2_prefs_button_action" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_vibration"
android:dependency="button_action_enable"

View File

@ -12,14 +12,14 @@
public static final String PREF_BUTTON_ACTION_PRESS_DELAY = "button_action_press_count_delay";
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_smart_button"
android:key="button_action_enable"
android:summary="@string/mi2_prefs_button_action_summary"
android:title="@string/mi2_prefs_button_action" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_vibration"
android:dependency="button_action_enable"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_camera_remote"
android:key="camera_remote"

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_devices_other"
android:key="pref_sony_connect_two_devices"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:icon="@drawable/ic_devices_other"
android:defaultValue="true"
android:key="use_custom_deviceicon"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_font_download"
android:key="use_custom_font"

View File

@ -7,7 +7,7 @@
android:summary="@string/device_card_activity_card_title_summary"
android:title="@string/device_card_activity_card_title">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:icon="@drawable/ic_activity_unknown_small"
android:key="prefs_activity_in_device_card"
@ -15,7 +15,7 @@
android:summary="@string/prefs_activity_in_device_card_title_summary"
android:title="@string/prefs_activity_in_device_card_title" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:dependency="prefs_activity_in_device_card"
android:icon="@drawable/ic_shoe_prints_many"
@ -24,7 +24,7 @@
android:summary="@string/prefs_activity_in_device_card_steps_title_summary"
android:title="@string/Steps" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:dependency="prefs_activity_in_device_card"
android:icon="@drawable/ic_distance_total"
@ -33,7 +33,7 @@
android:summary="@string/prefs_activity_in_device_card_distance_title_summary"
android:title="@string/Distance" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:dependency="prefs_activity_in_device_card"
android:icon="@drawable/ic_activity_sleep"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_language"
android:key="device_intents"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_language"
android:key="device_internet_access"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:icon="@drawable/ic_signal_cellular_connected_no_internet_4_bar"
android:defaultValue="false"
android:key="disconnect_notification_noshed"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:icon="@drawable/ic_person"
android:key="display_caller"

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_arrow_upward"
android:key="do_not_disturb_lift_wrist"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_settings_remote"
android:key="expose_hr_thirdparty"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_rotate_left"
android:key="fake_ring_duration"

View File

@ -11,13 +11,13 @@
<PreferenceCategory
android:key="pref_workout_detection_running"
android:title="@string/activity_type_running">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="activity_recognize_running_enabled"
android:title="@string/pref_workout_detection_enabled"
android:summary="@string/pref_workout_detection_summary"
android:icon="@drawable/ic_activity_running"/>
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="activity_recognize_running_ask_first"
android:title="@string/pref_workout_detection_ask_first"
@ -37,13 +37,13 @@
<PreferenceCategory
android:key="pref_workout_detection_biking"
android:title="@string/activity_type_biking">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="activity_recognize_biking_enabled"
android:title="@string/pref_workout_detection_enabled"
android:summary="@string/pref_workout_detection_summary"
android:icon="@drawable/ic_activity_biking"/>
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="activity_recognize_biking_ask_first"
android:title="@string/pref_workout_detection_ask_first"
@ -63,13 +63,13 @@
<PreferenceCategory
android:key="pref_workout_detection_walking"
android:title="@string/activity_type_walking">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="activity_recognize_walking_enabled"
android:title="@string/pref_workout_detection_enabled"
android:summary="@string/pref_workout_detection_summary"
android:icon="@drawable/ic_activity_walking"/>
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="activity_recognize_walking_ask_first"
android:title="@string/pref_workout_detection_ask_first"
@ -89,13 +89,13 @@
<PreferenceCategory
android:key="pref_workout_detection_rowing"
android:title="@string/activity_type_rowing">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="activity_recognize_rowing_enabled"
android:title="@string/pref_workout_detection_enabled"
android:summary="@string/pref_workout_detection_summary"
android:icon="@drawable/ic_activity_rowing"/>
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="activity_recognize_rowing_ask_first"
android:title="@string/pref_workout_detection_ask_first"
@ -146,12 +146,12 @@
android:title="@string/pref_title_developer_settings"
android:summary="@string/pref_summary_developer_settings">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="save_raw_activity_files"
android:title="@string/pref_qhybrid_save_raw_activity_files" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="dangerous_external_intents"
android:title="@string/qhybrid_pref_title_external_intents"
@ -165,7 +165,7 @@
android:targetClass="nodomain.freeyourgadget.gadgetbridge.devices.qhybrid.FileManagementActivity" />
</Preference>
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:key="enable_on_device_confirmation"
android:title="@string/qhybrid_title_on_device_confirmation"

View File

@ -11,13 +11,13 @@
android:targetClass="nodomain.freeyourgadget.gadgetbridge.devices.qhybrid.HRConfigActivity" />
</Preference>
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_filter_b_and_w"
android:key="force_white_color_scheme"
android:summary="@string/pref_summary_force_white_color_scheme"
android:title="@string/pref_title_force_white_color_scheme" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_circle"
android:key="widget_draw_circles"

View File

@ -8,13 +8,13 @@
android:title="@string/prefs_ambient_mode">
<PreferenceCategory android:title="@string/prefs_ambient_mode">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_hearing"
android:key="pref_galaxy_buds_ambient_mode"
android:summary="Hear surrounding sounds"
android:title="@string/prefs_ambient_sound" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:dependency="pref_galaxy_buds_ambient_mode"
android:icon="@drawable/ic_voice"
@ -39,13 +39,13 @@
android:persistent="false"
android:title="@string/prefs_equalizer">
<PreferenceCategory android:title="@string/prefs_equalizer">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_graphic_eq"
android:key="pref_galaxy_buds_equalizer"
android:summary="@string/prefs_equalizer_summary"
android:title="@string/prefs_equalizer" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:dependency="pref_galaxy_buds_equalizer"
android:icon="@drawable/ic_music_note"
@ -69,7 +69,7 @@
android:persistent="false"
android:title="@string/prefs_galaxy_touch_options">
<PreferenceCategory android:title="@string/prefs_galaxy_touch_options">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:disableDependentsState="true"
android:icon="@drawable/ic_lock_open"
@ -95,7 +95,7 @@
</PreferenceCategory>
</PreferenceScreen>
<PreferenceCategory android:title="@string/prefs_galaxy_buds_experimental">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_videogame"
android:key="pref_galaxy_buds_game_mode"

View File

@ -36,14 +36,14 @@
android:title="@string/prefs_ambient_settings_title">
<PreferenceCategory android:title="@string/prefs_ambient_sound">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_phone"
android:key="pref_galaxy_buds_ambient_mode_during_call"
android:summary="@string/prefs_ambient_sound_during_call_summary"
android:title="@string/prefs_ambient_sound_during_call_title" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_hearing"
android:key="pref_galaxy_buds_ambient_sound"
@ -97,7 +97,7 @@
android:persistent="false"
android:title="@string/prefs_galaxy_touch_options">
<PreferenceCategory android:title="@string/prefs_galaxy_touch_options">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:icon="@drawable/ic_touch"
android:key="pref_galaxy_buds_lock_touch"
@ -139,7 +139,7 @@
android:summary="%s"
android:title="@string/prefs_switch_control_right" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:dependency="pref_galaxy_buds_lock_touch"
android:icon="@drawable/ic_touch"
@ -154,20 +154,20 @@
android:key="prefs_settings"
android:persistent="false"
android:title="@string/title_activity_settings">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_hearing"
android:key="pref_galaxy_buds_pro_in_ear_detection"
android:summary="@string/prefs_in_ear_detection_summary"
android:title="@string/nothing_prefs_inear_title" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_auto_awesome"
android:key="prefs_galaxy_buds_seamless_connection"
android:summary="@string/prefs_seamless_connection_switch_summary"
android:title="@string/prefs_seamless_connection_switch_title" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_hearing"
android:key="pref_galaxy_buds_noise_controls_with_one_earbud"
@ -185,7 +185,7 @@
app:showSeekBarValue="true" />
<PreferenceCategory android:title="@string/prefs_galaxy_buds_experimental">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_videogame"
android:key="pref_galaxy_buds_game_mode"
@ -193,7 +193,7 @@
android:title="@string/prefs_game_mode" />
</PreferenceCategory>
<!-- <SwitchPreference
<!-- <SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_graphic_eq"
android:key="pref_galaxy_buds_pro_read_notifications_outloud"

View File

@ -16,7 +16,7 @@
android:title="@string/prefs_ambient_settings_title">
<PreferenceCategory android:title="@string/prefs_voice_detect">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_voice"
android:key="pref_galaxy_buds_pro_voice_detect"
@ -36,14 +36,14 @@
<PreferenceCategory android:title="@string/prefs_ambient_sound">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_phone"
android:key="pref_galaxy_buds_ambient_mode_during_call"
android:summary="@string/prefs_ambient_sound_during_call_summary"
android:title="@string/prefs_ambient_sound_during_call_title" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_hearing"
android:key="pref_galaxy_buds_ambient_sound"
@ -96,7 +96,7 @@
android:persistent="false"
android:title="@string/prefs_galaxy_touch_options">
<PreferenceCategory android:title="@string/prefs_galaxy_touch_options">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:icon="@drawable/ic_touch"
android:key="pref_galaxy_buds_lock_touch"
@ -138,7 +138,7 @@
android:summary="%s"
android:title="@string/prefs_switch_control_right" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:dependency="pref_galaxy_buds_lock_touch"
android:icon="@drawable/ic_touch"
@ -153,20 +153,20 @@
android:key="prefs_settings"
android:persistent="false"
android:title="@string/title_activity_settings">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_hearing"
android:key="pref_galaxy_buds_pro_in_ear_detection"
android:summary="@string/prefs_in_ear_detection_summary"
android:title="@string/nothing_prefs_inear_title" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_auto_awesome"
android:key="prefs_galaxy_buds_seamless_connection"
android:summary="@string/prefs_seamless_connection_switch_summary"
android:title="@string/prefs_seamless_connection_switch_title" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_hearing"
android:key="pref_galaxy_buds_noise_controls_with_one_earbud"
@ -184,7 +184,7 @@
app:showSeekBarValue="true" />
<PreferenceCategory android:title="@string/prefs_galaxy_buds_experimental">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_videogame"
android:key="pref_galaxy_buds_game_mode"
@ -192,7 +192,7 @@
android:title="@string/prefs_game_mode" />
</PreferenceCategory>
<!-- <SwitchPreference
<!-- <SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_graphic_eq"
android:key="pref_galaxy_buds_pro_read_notifications_outloud"

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_hearing"
android:key="pref_galaxy_buds_live_anc"
@ -23,7 +23,7 @@
android:persistent="false"
android:title="@string/prefs_galaxy_touch_options">
<PreferenceCategory android:title="@string/prefs_galaxy_touch_options">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:disableDependentsState="true"
android:icon="@drawable/ic_lock_open"
@ -49,14 +49,14 @@
</PreferenceCategory>
</PreferenceScreen>
<PreferenceCategory android:title="@string/prefs_galaxy_buds_experimental">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_videogame"
android:key="pref_galaxy_buds_game_mode"
android:summary="@string/prefs_game_mode_summary"
android:title="@string/prefs_game_mode" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_engineering"
android:key="pref_galaxy_buds_live_pressure_relief"

View File

@ -46,7 +46,7 @@
android:title="@string/prefs_ambient_settings_title">
<PreferenceCategory android:title="@string/prefs_voice_detect">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_voice"
android:key="pref_galaxy_buds_pro_voice_detect"
@ -66,14 +66,14 @@
<PreferenceCategory android:title="@string/prefs_ambient_sound">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_phone"
android:key="pref_galaxy_buds_ambient_mode_during_call"
android:summary="@string/prefs_ambient_sound_during_call_summary"
android:title="@string/prefs_ambient_sound_during_call_title" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_hearing"
android:key="pref_galaxy_buds_ambient_sound"
@ -127,7 +127,7 @@
android:persistent="false"
android:title="@string/prefs_galaxy_touch_options">
<PreferenceCategory android:title="@string/prefs_galaxy_touch_options">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:disableDependentsState="true"
android:icon="@drawable/ic_lock_open"
@ -173,7 +173,7 @@
android:summary="%s"
android:title="@string/prefs_switch_control_right" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:dependency="pref_galaxy_buds_lock_touch"
android:icon="@drawable/ic_touch"
@ -188,20 +188,20 @@
android:key="prefs_settings"
android:persistent="false"
android:title="@string/title_activity_settings">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_hearing"
android:key="pref_galaxy_buds_pro_in_ear_detection"
android:summary="@string/prefs_in_ear_detection_summary"
android:title="@string/nothing_prefs_inear_title" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_auto_awesome"
android:key="pref_galaxy_buds_pro_seamless_connection"
android:summary="@string/prefs_seamless_connection_switch_summary"
android:title="@string/prefs_seamless_connection_switch_title" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_hearing"
android:key="pref_galaxy_buds_noise_controls_with_one_earbud"
@ -219,7 +219,7 @@
app:showSeekBarValue="true" />
<PreferenceCategory android:title="@string/prefs_galaxy_buds_experimental">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_videogame"
android:key="pref_galaxy_buds_game_mode"
@ -227,7 +227,7 @@
android:title="@string/prefs_game_mode" />
</PreferenceCategory>
<!-- <SwitchPreference
<!-- <SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_graphic_eq"
android:key="pref_galaxy_buds_pro_read_notifications_outloud"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_star_gray"
android:key="fitness_goal_notification"

View File

@ -47,7 +47,7 @@
android:key="pref_header_agps"
android:title="@string/pref_agps_header">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="pref_agps_expiry_reminder_enabled"
android:title="@string/pref_agps_expiry_reminder_enabled" />

View File

@ -7,7 +7,7 @@
android:summary="@string/mi2_prefs_heart_rate_monitoring_summary"
android:title="@string/mi2_prefs_heart_rate_monitoring">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_activity_sleep"
android:key="heartrate_sleep_detection"

View File

@ -7,7 +7,7 @@
android:summary="@string/mi2_prefs_heart_rate_monitoring_summary"
android:title="@string/mi2_prefs_heart_rate_monitoring">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_activity_sleep"
android:key="heartrate_sleep_detection"
@ -24,7 +24,7 @@
<!-- Activity Monitoring -->
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_activity_unknown_small"
android:key="heartrate_activity_monitoring"

View File

@ -7,7 +7,7 @@
android:summary="@string/mi2_prefs_heart_rate_monitoring_alerts_summary"
android:title="@string/mi2_prefs_heart_rate_monitoring">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_activity_sleep"
android:key="heartrate_sleep_detection"
@ -24,7 +24,7 @@
<!-- Activity Monitoring -->
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_activity_unknown_small"
android:key="heartrate_activity_monitoring"
@ -33,7 +33,7 @@
<!-- Heart Rate Alerts -->
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_warning_gray"
android:key="heartrate_alert_enabled"
@ -52,7 +52,7 @@
<!-- Stress Monitoring -->
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_mood_bad"
android:key="heartrate_stress_monitoring"

View File

@ -11,13 +11,13 @@
android:key="pref_key_header_heartrate_sleep"
android:title="@string/pref_header_heartrate_sleep">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_activity_sleep"
android:key="heartrate_sleep_detection"
android:title="@string/miband_prefs_hr_sleep_detection" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_activity_sleep"
android:key="heartrate_sleep_breathing_quality_monitoring"
@ -40,7 +40,7 @@
<!-- Activity Monitoring -->
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_activity_unknown_small"
android:key="heartrate_activity_monitoring"
@ -78,14 +78,14 @@
android:key="pref_key_header_stress"
android:title="@string/pref_header_stress">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_mood_bad"
android:key="heartrate_stress_monitoring"
android:summary="@string/prefs_stress_monitoring_description"
android:title="@string/prefs_stress_monitoring_title" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:dependency="heartrate_stress_monitoring"
android:key="heartrate_stress_relaxation_reminder"
@ -98,7 +98,7 @@
android:key="pref_key_header_spo2"
android:title="@string/pref_header_spo2">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="spo2_all_day_monitoring_enabled"
android:summary="@string/prefs_spo2_monitoring_description"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:icon="@drawable/ic_mtu"
android:defaultValue="true"
android:key="allow_high_mtu"

View File

@ -7,7 +7,7 @@
android:summary="@string/prefs_hourly_chime_summary"
android:title="@string/prefs_hourly_chime">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="hourly_chime_enable"
android:title="@string/prefs_hourly_chime"

View File

@ -56,7 +56,7 @@
android:title="Reply Text"
app:useSimpleSummaryProvider="true" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="zepp_os_alexa_ask_more_input"
android:summary="Continue listening after sending the reply"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:icon="@drawable/ic_timer"
android:key="huami_truncate_fetch_operation_timestamps"

View File

@ -7,7 +7,7 @@
android:summary="@string/lefun_prefs_hydration_reminder_summary"
android:title="@string/lefun_prefs_hydration_reminder_title">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="pref_hydration_switch"
android:title="@string/lefun_prefs_hydration_reminder_title" />

View File

@ -7,7 +7,7 @@
android:summary="@string/mi2_prefs_inactivity_warnings_summary"
android:title="@string/mi2_prefs_inactivity_warnings">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="inactivity_warnings_enable"
android:title="@string/mi2_prefs_inactivity_warnings"

View File

@ -7,7 +7,7 @@
android:summary="@string/mi2_prefs_inactivity_warnings_summary"
android:title="@string/mi2_prefs_inactivity_warnings">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="inactivity_warnings_enable"
android:title="@string/mi2_prefs_inactivity_warnings"
@ -33,7 +33,7 @@
android:key="inactivity_warnings_end"
android:title="@string/mi2_prefs_do_not_disturb_end" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:dependency="inactivity_warnings_enable"
android:key="inactivity_warnings_dnd"

View File

@ -7,7 +7,7 @@
android:summary="@string/mi2_prefs_inactivity_warnings_summary"
android:title="@string/mi2_prefs_inactivity_warnings">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="inactivity_warnings_enable"
android:summary="@string/mi2_prefs_inactivity_warnings_summary"
@ -25,7 +25,7 @@
android:key="inactivity_warnings_end"
android:title="@string/mi2_prefs_do_not_disturb_end" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:dependency="inactivity_warnings_enable"
android:key="inactivity_warnings_dnd"

View File

@ -10,7 +10,7 @@
<!-- workaround for missing toolbar -->
<PreferenceCategory android:title="@string/mi2_prefs_inactivity_warnings_summary" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="inactivity_warnings_enable"
android:summary="@string/mi2_prefs_inactivity_warnings_summary"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:icon="@drawable/ic_chair"
android:defaultValue="false"
android:key="inactivity_warnings_enable_noshed"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:icon="@drawable/ic_activity_unknown_small"
android:defaultValue="false"
android:key="keep_activity_data_on_device"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_vibration"
android:key="key_vibration"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:icon="@drawable/ic_arrow_upward"
android:defaultValue="false"
android:key="activate_display_on_lift_wrist_noshed"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:icon="@drawable/ic_lock_open"
android:defaultValue="false"
android:key="lock"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:icon="@drawable/ic_mtu"
android:defaultValue="true"
android:key="low_latency_fw_update"

View File

@ -10,7 +10,7 @@
android:summary="@string/mi2_prefs_display_items_summary"
android:title="@string/mi2_prefs_display_items" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:icon="@drawable/ic_font_download"
android:key="mi2_enable_text_notifications"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="force_new_protocol"
android:summary="@string/pref_summary_huami_force_new_protocol"

View File

@ -7,7 +7,7 @@
android:summary="@string/pref_morning_updates_summary"
android:title="@string/pref_morning_updates_title">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_wb_sunny"
android:key="morning_updates_enabled"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:icon="@drawable/ic_extension"
android:key="pref_nothing_inear_detection"

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_notifications"
android:key="notification_enable"

View File

@ -15,19 +15,19 @@
android:summary="%s"
android:title="@string/pref_title_language" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_rotate_left"
android:key="offline_voice_respond_turn_wrist"
android:title="@string/offline_voice_respond_turn_wrist" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_always_on_display"
android:key="offline_voice_respond_screen_on"
android:title="@string/offline_voice_respond_screen_on" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_always_on_display"
android:key="offline_voice_response_during_screen_lighting"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_radio"
android:key="operating_sounds"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:icon="@drawable/ic_settings_applications"
android:key="overwrite_settings_on_connection"

View File

@ -7,7 +7,7 @@
android:summary="@string/prefs_password_summary"
android:title="@string/prefs_password">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_password"
android:key="pref_password_enabled"

View File

@ -45,14 +45,14 @@
android:key="pref_bluetooth_calls_settings_header"
android:title="@string/bluetooth_calls_settings">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_voice"
android:key="bluetooth_calls_enabled"
android:summary="@string/pref_summary_receive_calls_watch"
android:title="@string/bluetooth_calls" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:icon="@drawable/ic_person"
android:key="display_caller"

View File

@ -3,7 +3,7 @@
<PreferenceCategory
android:title="@string/connection_over_bt_classic" />
<SwitchPreference
<SwitchPreferenceCompat
android:icon="@drawable/ic_bluetooth"
android:key="prefs_key_device_reconnect_on_acl"
android:title="@string/autoconnect_from_device_title"

View File

@ -3,7 +3,7 @@
<PreferenceCategory
android:title="@string/connection_over_ble" />
<SwitchPreference
<SwitchPreferenceCompat
android:icon="@drawable/ic_bluetooth"
android:key="prefs_key_device_auto_reconnect"
android:title="@string/auto_reconnect_ble_title"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:icon="@drawable/ic_verified"
android:defaultValue="false"
android:key="relax_firmware_checks"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_rotate_left"
android:key="rotate_wrist_to_cycle_info"

View File

@ -6,7 +6,7 @@
android:persistent="false"
android:title="@string/pref_screen_brightness">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:icon="@drawable/ic_wb_sunny"
android:key="screen_auto_brightness"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:icon="@drawable/ic_notifications"
android:key="screen_on_on_notifications"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:icon="@drawable/ic_developer_mode"
android:defaultValue="false"
android:key="third_party_apps_set_settings"

View File

@ -6,14 +6,14 @@
android:persistent="false"
android:title="@string/pref_sleep_mode_title">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_activity_sleep"
android:key="pref_sleep_mode_sleep_screen"
android:summary="@string/pref_sleep_mode_sleep_screen_summary"
android:title="@string/pref_sleep_mode_sleep_screen_title" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_auto_awesome"
android:key="pref_sleep_mode_smart_enable"

View File

@ -21,7 +21,7 @@
android:max="19"
android:title="@string/sony_ambient_sound_level" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:icon="@drawable/ic_voice"
android:key="pref_sony_focus_voice"

View File

@ -21,7 +21,7 @@
android:max="19"
android:title="@string/sony_ambient_sound_level" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:icon="@drawable/ic_voice"
android:key="pref_sony_focus_voice"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_extension"
android:key="pref_sony_audio_upsampling"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:icon="@drawable/ic_notifications"
android:key="pref_sony_notification_voice_guide"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_pause"
android:key="pref_sony_pause_when_taken_off"

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_voice"
android:key="pref_sony_speak_to_chat"

View File

@ -8,7 +8,7 @@
android:summary="@string/sony_speak_to_chat_summary"
android:title="@string/sony_speak_to_chat">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_voice"
android:key="pref_sony_speak_to_chat"
@ -28,7 +28,7 @@
android:summary="%s"
android:title="@string/sony_speak_to_chat_sensitivity" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:dependency="pref_sony_speak_to_chat"
android:icon="@drawable/ic_voice"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:icon="@drawable/ic_touch"
android:key="pref_sony_touch_sensor"

View File

@ -1,12 +1,12 @@
<?xml version="1.0" encoding="utf-8"?>
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:icon="@drawable/ic_bolt"
android:key="stamina_preference"
android:title="@string/sonyswr12_settings_stamina"
android:defaultValue="false"
android:summary="@string/sonyswr12_settings_stamina_summary" />
<SwitchPreference
<SwitchPreferenceCompat
android:icon="@drawable/ic_vibration"
android:key="vibration_preference"
android:title="@string/sonyswr12_settings_low_vibration"

View File

@ -13,31 +13,31 @@
android:max="100"
android:title="@string/menuitem_volume" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_rotate_left"
android:key="crown_vibration"
android:title="@string/pref_crown_vibration" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_warning_gray"
android:key="alert_tone"
android:title="@string/pref_alert_tone" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_volume_off"
android:key="cover_to_mute"
android:title="@string/pref_cover_to_mute" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_vibration"
android:key="vibrate_for_alert"
android:title="@string/pref_vibrate_for_alert" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_voice"
android:key="text_to_speech"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_lock_open"
android:key="swipe_unlock"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_calendar_sync"
android:key="sync_calendar"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_translate"
android:key="banglejs_text_bitmap"

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_vibration"
android:key="vibration_enable"

View File

@ -14,13 +14,13 @@
android:max="10"
android:title="@string/pref_title_notifications_and_calls_repeat_on_call"
app:showSeekBarValue="true" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="notification_enable_continious_ring"
android:title="@string/prefs_notifications_and_calls_continious_ring" />
<PreferenceCategory
android:title="@string/pref_screen_notification_profile_missed_call"/>
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="notification_enable_missed_call"
android:title="@string/pref_notifications_and_calls_enable_misscall"
@ -35,12 +35,12 @@
app:showSeekBarValue="true" />
<PreferenceCategory
android:title="@string/pref_header_notifications_and_calls_callhandling"/>
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="notification_button_reject"
android:summary="@string/pref_summary_notifications_and_calls_title_reject"
android:title="@string/prefs_notifications_and_calls_reject" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="notification_shake_reject"
android:summary="@string/pref_summary_notifications_and_calls_title_shake_reject"
@ -59,13 +59,13 @@
android:entryValues="@array/language_only_EN_CH_values"
android:key="language"
android:summary="%s" />
<SwitchPreference
<SwitchPreferenceCompat
android:icon="@drawable/ic_access_time"
android:defaultValue="false"
android:key="pref_device_spec_settings_force_time"
android:summary="@string/pref_summary_device_spec_settings_title_force_time"
android:title="@string/pref_title_device_spec_settings_force_time" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="show_raw_graph"
android:title="@string/pref_title_device_spec_settings_show_raw_graph" />

View File

@ -3,7 +3,7 @@
<!-- Not including PREF_LANGUAGE here since GadgetBridge seems to add it for us -->
<PreferenceCategory
android:title="@string/prefs_wena3_title_activity">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:key="pref_wena3_background_sync"
android:icon="@drawable/ic_access_time"
@ -53,7 +53,7 @@
</PreferenceCategory>
<PreferenceCategory
android:title="@string/prefs_wena3_receive_calls_title">
<SwitchPreference
<SwitchPreferenceCompat
android:title="@string/prefs_wena3_receive_calls_item"
android:key="pref_wena3_receive_calls"
android:icon="@drawable/ic_phone"
@ -96,26 +96,26 @@
android:icon="@drawable/ic_hourglass_empty"
android:summary="%s"
android:title="@string/prefs_screen_timeout" />
<SwitchPreference
<SwitchPreferenceCompat
android:title="@string/mi2_prefs_activate_display_on_lift"
android:key="pref_screen_lift_wrist"
android:icon="@drawable/ic_watch"
android:summary="@string/prefs_wena3_hint_lift_wrist"
android:defaultValue="false"
/>
<SwitchPreference
<SwitchPreferenceCompat
android:title="@string/prefs_wena3_item_weather_statusbar"
android:icon="@drawable/ic_wb_sunny"
android:key="pref_wena3_weather_in_statusbar"
android:summary="@string/prefs_wena3_hint_weather_statusbar"
android:defaultValue="true" />
<SwitchPreference
<SwitchPreferenceCompat
android:title="@string/prefs_wena3_item_rich_design"
android:icon="@drawable/ic_auto_awesome"
android:key="pref_wena3_rich_design_mode"
android:summary="@string/prefs_wena3_hint_rich_design"
android:defaultValue="false" />
<SwitchPreference
<SwitchPreferenceCompat
android:title="@string/prefs_wena3_item_large_font"
android:icon="@drawable/ic_font_size"
android:key="pref_wena3_large_font_size"
@ -190,7 +190,7 @@
android:entries="@array/prefs_wena3_vibration_strength_names_list"
android:entryValues="@array/prefs_wena3_vibration_strength_values_list"
android:summary="%s" />
<SwitchPreference
<SwitchPreferenceCompat
android:title="@string/prefs_wena3_vibration_smart_item"
android:key="pref_wena3_vibration_smart"
android:defaultValue="true" />

View File

@ -17,7 +17,7 @@
android:summary="@string/pref_workout_detection_categories_summary"
android:title="@string/pref_workout_detection_categories_title" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_notifications"
android:key="workout_detection_alert"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_always_on_display"
android:key="workout_keep_screen_on"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_gps_location"
android:key="workout_send_gps_to_band"

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_activity_unknown_small"
android:key="workout_start_on_phone"

View File

@ -2,21 +2,21 @@
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:key="ignore_bonded_devices"
android:layout="@layout/preference_checkbox"
android:summary="@string/ignore_bonded_devices_description"
android:title="@string/ignore_bonded_devices"
app:iconSpaceReserved="false" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="enable_companiondevice_pairing"
android:layout="@layout/preference_checkbox"
android:summary="@string/companiondevice_pairing_details"
android:title="@string/companiondevice_pairing"
app:iconSpaceReserved="false" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:key="discover_unsupported_devices"
android:layout="@layout/preference_checkbox"

View File

@ -29,7 +29,7 @@
android:singleLineTitle="false"
android:title="@string/watchface_setting_desc_wrist_flick"
app:iconSpaceReserved="false" />
<SwitchPreference
<SwitchPreferenceCompat
android:key="pref_hybridhr_watchface_wrist_flick_relative"
android:persistent="false"
android:singleLineTitle="false"
@ -91,19 +91,19 @@
android:title="@string/watchface_setting_title_power_saving"
app:iconSpaceReserved="false">
<SwitchPreference
<SwitchPreferenceCompat
android:key="pref_hybridhr_watchface_power_saving_display"
android:persistent="false"
android:singleLineTitle="false"
android:title="@string/watchface_setting_power_saving_display"
app:iconSpaceReserved="false" />
<SwitchPreference
<SwitchPreferenceCompat
android:key="pref_hybridhr_watchface_power_saving_hands"
android:persistent="false"
android:singleLineTitle="false"
android:title="@string/watchface_setting_power_saving_hands"
app:iconSpaceReserved="false" />
<SwitchPreference
<SwitchPreferenceCompat
android:key="pref_hybridhr_watchface_light_up_on_notification"
android:persistent="false"
android:singleLineTitle="false"

View File

@ -92,13 +92,13 @@
android:persistent="false"
android:title="@string/watchface_dialog_widget_update_timeout"
app:iconSpaceReserved="false" />
<SwitchPreference
<SwitchPreferenceCompat
android:key="pref_hybridhr_widget_custom_hide_text"
android:persistent="false"
android:singleLineTitle="false"
android:title="@string/watchface_dialog_widget_timeout_hide_text"
app:iconSpaceReserved="false" />
<SwitchPreference
<SwitchPreferenceCompat
android:key="pref_hybridhr_widget_custom_show_circle"
android:persistent="false"
android:singleLineTitle="false"

View File

@ -13,7 +13,7 @@
app:iconSpaceReserved="false"
app:useSimpleSummaryProvider="true"/>
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="true"
android:key="hplus_alldayhr"
android:layout="@layout/preference_checkbox"

View File

@ -54,7 +54,7 @@
android:key="pref_key_header_loyalty_cards_sync_options"
android:title="@string/loyalty_cards_sync_options">
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_list_numbered"
android:key="loyalty_cards_sync_groups_only"
@ -71,13 +71,13 @@
android:summary=""
android:title="@string/loyalty_cards_sync_groups" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_archive"
android:key="loyalty_cards_sync_archived"
android:title="@string/loyalty_cards_sync_archived" />
<SwitchPreference
<SwitchPreferenceCompat
android:defaultValue="false"
android:icon="@drawable/ic_star_gray"
android:key="loyalty_cards_sync_starred"

Some files were not shown because too many files have changed in this diff Show More