1
0
mirror of https://codeberg.org/Freeyourgadget/Gadgetbridge synced 2024-12-29 12:05:53 +01:00

Bump version ot 0.39

Redesign Settings page
This commit is contained in:
mamutcho 2019-11-19 20:51:37 +02:00
parent 7d95eae14c
commit e3f838afa0
10 changed files with 260 additions and 205 deletions

View File

@ -73,6 +73,10 @@
android:name=".devices.zetime.ZeTimePreferenceActivity"
android:label="@string/zetime_title_settings"
android:parentActivityName=".activities.SettingsActivity" />
<activity
android:name=".devices.lenovo.watchxplus.WatchXPlusPreferenceActivity"
android:label="@string/preferences_watchxplus_settings"
android:parentActivityName=".activities.SettingsActivity" />
<activity
android:name=".activities.ActivitySummariesActivity"
android:label="@string/activity_summaries"

View File

@ -55,6 +55,7 @@ import nodomain.freeyourgadget.gadgetbridge.R;
import nodomain.freeyourgadget.gadgetbridge.database.PeriodicExporter;
import nodomain.freeyourgadget.gadgetbridge.devices.DeviceManager;
import nodomain.freeyourgadget.gadgetbridge.devices.lenovo.watchxplus.WatchXPlusConstants;
import nodomain.freeyourgadget.gadgetbridge.devices.lenovo.watchxplus.WatchXPlusPreferenceActivity;
import nodomain.freeyourgadget.gadgetbridge.devices.miband.MiBandPreferencesActivity;
import nodomain.freeyourgadget.gadgetbridge.devices.zetime.ZeTimePreferenceActivity;
import nodomain.freeyourgadget.gadgetbridge.activities.charts.ChartsPreferencesActivity;
@ -127,6 +128,15 @@ public class SettingsActivity extends AbstractSettingsActivity {
}
});
pref = findPreference("pref_key_watchxplus");
pref.setOnPreferenceClickListener(new Preference.OnPreferenceClickListener() {
public boolean onPreferenceClick(Preference preference) {
Intent enableIntent = new Intent(SettingsActivity.this, WatchXPlusPreferenceActivity.class);
startActivity(enableIntent);
return true;
}
});
pref = findPreference("pref_key_blacklist");
pref.setOnPreferenceClickListener(new Preference.OnPreferenceClickListener() {
public boolean onPreferenceClick(Preference preference) {
@ -211,52 +221,6 @@ public class SettingsActivity extends AbstractSettingsActivity {
});
pref = findPreference("wxp_button_BP_calibration_list");
pref.setOnPreferenceChangeListener(new Preference.OnPreferenceChangeListener() {
@Override
public boolean onPreferenceChange(Preference preference, Object newVal) {
//preference.setSummary("Calibrating, please wait... (if no result after 15s. re-run)");
GBApplication.deviceService().onSendConfiguration("BP_CAL");
return true;
}
});
pref = findPreference("watchxplus_longsit_period");
pref.setOnPreferenceChangeListener(new Preference.OnPreferenceChangeListener() {
@Override
public boolean onPreferenceChange(Preference preference, Object newVal) {
GBApplication.deviceService().onSendConfiguration("LONG_SIT");
return true;
}
});
pref = findPreference("watchxplus_longsit_switch");
pref.setOnPreferenceChangeListener(new Preference.OnPreferenceChangeListener() {
@Override
public boolean onPreferenceChange(Preference preference, Object newVal) {
GBApplication.deviceService().onSendConfiguration("LONG_SIT");
return true;
}
});
pref = findPreference("wxp_power_mode");
pref.setOnPreferenceChangeListener(new Preference.OnPreferenceChangeListener() {
@Override
public boolean onPreferenceChange(Preference preference, Object newVal) {
GBApplication.deviceService().onSendConfiguration("WXP_POWER_MODE");
return true;
}
});
pref = findPreference(WatchXPlusConstants.PREF_WXP_LANGUAGE);
pref.setOnPreferenceChangeListener(new Preference.OnPreferenceChangeListener() {
@Override
public boolean onPreferenceChange(Preference preference, Object newVal) {
GBApplication.deviceService().onSendConfiguration("WXP_LANGUAGE");
return true;
}
});
final Preference unit = findPreference(PREF_MEASUREMENT_SYSTEM);
unit.setOnPreferenceChangeListener(new Preference.OnPreferenceChangeListener() {
@Override

View File

@ -34,7 +34,7 @@ public final class WatchXPlusConstants extends LenovoWatchConstants {
public static final String PREF_DISCONNECT_REMIND = "disconnect_notification";
public static final String PREF_FIND_PHONE = "prefs_find_phone";
public static final String PREF_FIND_PHONE_DURATION = "prefs_find_phone_duration";
public static final String PREF_ALTITUDE = "watchxplus_altitude";
public static final String PREF_ALTITUDE = "pref_watchxplus_altitude";
public static final String PREF_REPEAT = "watchxplus_repeat";
public static final String PREF_CONTINIOUS = "watchxplus_continious";
public static final String PREF_MISSED_CALL = "watchxplus_missed";
@ -48,9 +48,11 @@ public final class WatchXPlusConstants extends LenovoWatchConstants {
public static final String PREF_DO_NOT_DISTURB = "do_not_disturb_no_auto";
public static final String PREF_DO_NOT_DISTURB_START = "do_not_disturb_no_auto_start";
public static final String PREF_DO_NOT_DISTURB_END = "do_not_disturb_no_auto_end";
public static final String PREF_LONGSIT_SWITCH = "watchxplus_longsit_switch";
public static final String PREF_LONGSIT_PERIOD = "watchxplus_longsit_period";
public static final String PREF_WXP_LANGUAGE = "wxp_language_pref";
public static final String PREF_LONGSIT_SWITCH = "pref_watchxplus_longsit_switch";
public static final String PREF_LONGSIT_PERIOD = "pref_watchxplus_longsit_period";
public static final String PREF_WXP_LANGUAGE = "pref_wxp_language";
public static final String PREF_POWER_MODE = "pref_wxp_power_mode";
// time format constants
public static final byte ARG_SET_TIMEMODE_24H = 0x00;

View File

@ -0,0 +1,65 @@
/* Copyright (C) 2018-2019 Sebastian Kranz
This file is part of Gadgetbridge.
Gadgetbridge is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as published
by the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Gadgetbridge is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
package nodomain.freeyourgadget.gadgetbridge.devices.lenovo.watchxplus;
import android.os.Bundle;
import android.preference.Preference;
import nodomain.freeyourgadget.gadgetbridge.GBApplication;
import nodomain.freeyourgadget.gadgetbridge.R;
import nodomain.freeyourgadget.gadgetbridge.activities.AbstractSettingsActivity;
import nodomain.freeyourgadget.gadgetbridge.activities.devicesettings.DeviceSettingsPreferenceConst;
public class WatchXPlusPreferenceActivity extends AbstractSettingsActivity {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
addPreferencesFromResource(R.xml.watchxplus_preferences);
// notifications
//addPreferenceHandlerFor(WatchXPlusConstants.PREF_REPEAT);
//addPreferenceHandlerFor(WatchXPlusConstants.PREF_CONTINIOUS);
//addPreferenceHandlerFor(WatchXPlusConstants.PREF_MISSED_CALL);
//addPreferenceHandlerFor(WatchXPlusConstants.PREF_MISSED_CALL_REPEAT);
//addPreferenceHandlerFor(WatchXPlusConstants.PREF_BUTTON_REJECT);
//addPreferenceHandlerFor(WatchXPlusConstants.PREF_SHAKE_REJECT);
// settings
addPreferenceHandlerFor(WatchXPlusConstants.PREF_POWER_MODE);
addPreferenceHandlerFor(WatchXPlusConstants.PREF_WXP_LANGUAGE);
addPreferenceHandlerFor(WatchXPlusConstants.PREF_LONGSIT_PERIOD);
addPreferenceHandlerFor(WatchXPlusConstants.PREF_LONGSIT_SWITCH);
// calibration
addPreferenceHandlerFor(WatchXPlusConstants.PREF_ALTITUDE);
addPreferenceHandlerFor(WatchXPlusConstants.PREF_BP_CAL_LOW);
addPreferenceHandlerFor(WatchXPlusConstants.PREF_BP_CAL_HIGH);
addPreferenceHandlerFor(WatchXPlusConstants.PREF_BP_CAL_SWITCH);
}
private void addPreferenceHandlerFor(final String preferenceKey) {
Preference pref = findPreference(preferenceKey);
pref.setOnPreferenceChangeListener(new Preference.OnPreferenceChangeListener() {
@Override public boolean onPreferenceChange(Preference preference, Object newVal) {
GBApplication.deviceService().onSendConfiguration(preferenceKey);
return true;
}
});
}
}

View File

@ -25,6 +25,7 @@ NEED TO BE DONE
WORK PROGRESS
Bump version to 0.39 (19.11.2019)
Send notification to watch
- On incoming call
- add function to cancel notification on watch (04.11.2019)
@ -65,6 +66,7 @@ WORK PROGRESS
- Implemented long sit reminder (inactivity reminder)[on, off, period] (17.11.2019)
- Set watch language [English, Chinese] (17.11.2019)
- Set watch units (metric/imperial) (17.11.2019)
- Redesign Device Settings (19.11.2019)
Activity data
- get steps per day

View File

@ -799,11 +799,35 @@ public class WatchXPlusDeviceSupport extends AbstractBTLEDeviceSupport {
SharedPreferences sharedPreferences = GBApplication.getDeviceSpecificSharedPrefs(this.getDevice().getAddress());
try {
builder = performInitialized("sendConfig: " + config);
LOG.info(" config changed:" + config);
switch (config) {
// settings from App Settings
case SettingsActivity.PREF_MEASUREMENT_SYSTEM:
setUnitsSettings();
break;
case ActivityUser.PREF_USER_STEPS_GOAL:
setFitnessGoal(builder);
break;
// settings from App Settings -> WatchXPlus settings
case WatchXPlusConstants.PREF_POWER_MODE:
setPowerMode();
break;
case WatchXPlusConstants.PREF_WXP_LANGUAGE:
setLanguageAndTimeFormat(builder, sharedPreferences);
break;
case WatchXPlusConstants.PREF_LONGSIT_PERIOD:
case WatchXPlusConstants.PREF_LONGSIT_SWITCH:
setLongSitHours(builder, sharedPreferences);
break;
// calibrations
case WatchXPlusConstants.PREF_ALTITUDE:
setAltitude(builder);
break;
case WatchXPlusConstants.PREF_BP_CAL_SWITCH:
sendBloodPressureCalibration();
break;
// settings from device card
case WatchXPlusConstants.PREF_ACTIVATE_DISPLAY:
setHeadsUpScreen(builder, sharedPreferences);
getShakeStatus(builder);
@ -820,21 +844,6 @@ public class WatchXPlusDeviceSupport extends AbstractBTLEDeviceSupport {
case WatchXPlusConstants.PREF_DO_NOT_DISTURB_END:
setQuiteHours(builder, sharedPreferences);
break;
case "BP_CAL":
sendBloodPressureCalibration();
break;
case "LONG_SIT":
setLongSitHours(builder, sharedPreferences);
break;
case "WXP_POWER_MODE":
setPowerMode(config);
break;
case "WXP_LANGUAGE":
setLanguageAndTimeFormat(builder, sharedPreferences);
break;
case "measurement_system":
setUnitsSettings();
break;
}
builder.queue(getQueue());
} catch (IOException e) {
@ -987,15 +996,14 @@ public class WatchXPlusDeviceSupport extends AbstractBTLEDeviceSupport {
}
/** set watch power
* @param config
* switch watch power mode
* modes (0- normal, 1- energysaving, 2- only watch)
*/
private WatchXPlusDeviceSupport setPowerMode(String config) {
int settingRead = prefs.getInt("wxp_power_mode", 0);
private WatchXPlusDeviceSupport setPowerMode() {
int settingRead = prefs.getInt(WatchXPlusConstants.PREF_POWER_MODE, 0);
byte[] bArr = new byte[1];
bArr[0] = (byte) settingRead;
LOG.info(" setting: " + config);
LOG.info(" setting power mode to: " + settingRead);
try {
TransactionBuilder builder = performInitialized("setPowerMode");
builder.write(getCharacteristic(WatchXPlusConstants.UUID_CHARACTERISTIC_WRITE),
@ -1882,8 +1890,7 @@ public class WatchXPlusDeviceSupport extends AbstractBTLEDeviceSupport {
// calibrate altitude
private WatchXPlusDeviceSupport setAltitude(TransactionBuilder transactionBuilder) {
int value = WatchXPlusDeviceCoordinator.getAltitude(getDevice().getAddress());
int mAltitude = value;
int mAltitude = WatchXPlusDeviceCoordinator.getAltitude(getDevice().getAddress());
if (mAltitude < 0) {
mAltitude = (Math.abs(mAltitude) ^ 65535) + 1;
}
@ -1897,7 +1904,7 @@ public class WatchXPlusDeviceSupport extends AbstractBTLEDeviceSupport {
buildCommand(WatchXPlusConstants.CMD_ALTITUDE,
WatchXPlusConstants.WRITE_VALUE,
bArr));
//LOG.info(" setAltitude: " + mAltitude);
LOG.info(" setAltitude: " + mAltitude);
return this;
}

View File

@ -293,7 +293,8 @@
<string name="prefs_wxp_continious">Известявай докато телефона звъни</string>
<string name="prefs_wxp_missed">Известие за пропуснато обаждане</string>
<string name="preferences_watchxplus_settings">Watch X Plus настройки</string>
<string name="pref_header_wxp_notification">Настройки на известията</string>
<string name="pref_header_wxp_notification_call">Известия при обаждане</string>
<string name="pref_header_wxp_notification_misscall">Известия при пропуснато обаждане</string>
<string name="pref_wxp_title_reject_summary">Изкл. - заглуши, Вкл. - откажи</string>
<string name="prefs_wxp_reject">Бутона заглушава/отказва повикване</string>
<string name="pref_wxp_title_shake_reject_summary">Повтаря действието на бутона</string>
@ -309,14 +310,16 @@
<string name="wxp_mode_normal">Нормален</string>
<string name="wxp_mode_saving">Икономичен</string>
<string name="wxp_mode_watch">Само часовник</string>
<string name="pref_wxp_title_repeat_on_missedcall_summary">Повтаряй известие за пропуснато повикване всяка минута за X пъти</string>
<string name="pref_wxp_title_repeat_on_missedcall">Повтаряй известието за пропуснато повикване</string>
<string name="pref_wxp_title_repeat_on_misscall_summary">Повтаряй известие за пропуснато повикване всяка минута за X пъти</string>
<string name="pref_wxp_title_repeat_on_misscall">Повтаряй известието за пропуснато повикване</string>
<string name="pref_header_wxp_notification_callhandling">Управление на обажданията</string>
<string name="pref_header_wxp_longsit">Напомняне за бездействие</string>
<string name="pref_wxp_longsit_period_summary">Напомняй ако няма активност за повече от X минути</string>
<string name="pref_wxp_longsit_switch_summary">Времевия интервал е от настройката за DND</string>
<string name="prefs_wxp_longsit_switch">Включи напомняне за активност</string>
<string name="pref_wxp_title_longsit">Период на неактивност (минути)</string>
<string name="wxp_language_title">Език</string>
<string name="pref_header_wxp_call_notification">Известия и Обаждания</string>
<string name="title_activity_sleepmonitor">Наблюдение/анализ на съня</string>
<string name="pref_write_logfiles">Съхраняване на log файлове</string>

View File

@ -199,7 +199,9 @@
<string name="prefs_wxp_continious">Vibration during phone ring</string>
<string name="prefs_wxp_missed">Vibration on missed call</string>
<string name="preferences_watchxplus_settings">Watch X Plus settings</string>
<string name="pref_header_wxp_notification">Notification settings</string>
<string name="pref_header_wxp_call_notification">Notifications and Calls</string>
<string name="pref_header_wxp_notification_call">Call notifications</string>
<string name="pref_header_wxp_notification_misscall">MissCall notifications</string>
<string name="pref_wxp_title_reject_summary">Off - ignore, On - reject</string>
<string name="prefs_wxp_reject">Button ignore/reject call</string>
<string name="pref_wxp_title_shake_reject_summary">Duplicates watch button action</string>
@ -215,14 +217,16 @@
<string name="wxp_mode_normal">Normal</string>
<string name="wxp_mode_saving">Power saving</string>
<string name="wxp_mode_watch">Only watch</string>
<string name="pref_wxp_title_repeat_on_missedcall_summary">Repeat missed call notification every minute for X times</string>
<string name="pref_wxp_title_repeat_on_missedcall">Repeat missed call notification</string>
<string name="pref_wxp_title_repeat_on_misscall_summary">Repeat missed call notification every minute for X times</string>
<string name="pref_wxp_title_repeat_on_misscall">Repeat missed call notification</string>
<string name="pref_header_wxp_notification_callhandling">Call Handling</string>
<string name="pref_header_wxp_longsit">Inactivity reminder</string>
<string name="pref_wxp_longsit_period_summary">Remind if there is no activity for more than X minutes</string>
<string name="pref_wxp_longsit_switch_summary">Inactivity time interval is from DND setting</string>
<string name="prefs_wxp_longsit_switch">Enable inactivity reminder</string>
<string name="pref_wxp_title_longsit">Inactivity period (minutes)</string>
<string name="wxp_language_title">Language</string>
<!-- Makibes HR3 Preferences -->
<string name="preferences_makibes_hr3_settings">Makibes HR3 settings</string>
<!-- ID115 Preferences -->

View File

@ -575,134 +575,10 @@
android:key="pref_key_zetime"
android:title="@string/zetime_title_settings"/>
<PreferenceScreen
<Preference
android:icon="@drawable/ic_device_watchxplus"
android:key="pref_key_watchxplus"
android:title="@string/preferences_watchxplus_settings">
<PreferenceCategory
android:key="pref_category_watchxplus_general"
android:title="@string/pref_header_wxp_notification">
<EditTextPreference
android:defaultValue="0"
android:key="watchxplus_repeat"
android:summary="@string/pref_wxp_title_repeat_on_call_summary"
android:title="@string/pref_wxp_title_repeat_on_call"/>
<CheckBoxPreference
android:layout="@layout/preference_checkbox"
android:defaultValue="false"
android:key="watchxplus_continious"
android:title="@string/prefs_wxp_continious" />
<CheckBoxPreference
android:layout="@layout/preference_checkbox"
android:defaultValue="false"
android:key="watchxplus_missed"
android:title="@string/prefs_wxp_missed" />
<EditTextPreference
android:defaultValue="0"
android:key="watchxplus_repeat_missedcall"
android:summary="@string/pref_wxp_title_repeat_on_missedcall_summary"
android:title="@string/pref_wxp_title_repeat_on_missedcall"/>
<CheckBoxPreference
android:layout="@layout/preference_checkbox"
android:defaultValue="false"
android:key="watchxplus_button_reject"
android:summary="@string/pref_wxp_title_reject_summary"
android:title="@string/prefs_wxp_reject" />
<CheckBoxPreference
android:layout="@layout/preference_checkbox"
android:defaultValue="false"
android:key="watchxplus_shake_reject"
android:summary="@string/pref_wxp_title_shake_reject_summary"
android:title="@string/prefs_wxp_shake_reject" />
</PreferenceCategory>
<PreferenceCategory
android:key="pref_category_watchxplus_settings"
android:title="@string/pref_header_wxp_settings">
<ListPreference
android:defaultValue="0"
android:title="@string/wxp_power_mode_title"
android:entries="@array/wxp_mode"
android:entryValues="@array/wxp_mode_values"
android:key="wxp_power_mode"
android:summary="%s" />
<ListPreference
android:defaultValue="1"
android:title="@string/pref_title_language"
android:entries="@array/wxp_language"
android:entryValues="@array/wxp_language_values"
android:key="wxp_language_pref"
android:summary="%s" />
<PreferenceScreen
android:key="pref_category_watchxplus_longsit_settings"
android:title="@string/pref_header_wxp_longsit">
<EditTextPreference
android:defaultValue="60"
android:key="watchxplus_longsit_period"
android:summary="@string/pref_wxp_longsit_period_summary"
android:title="@string/pref_wxp_title_longsit"/>
<CheckBoxPreference
android:layout="@layout/preference_checkbox"
android:defaultValue="false"
android:key="watchxplus_longsit_switch"
android:summary="@string/pref_wxp_longsit_switch_summary"
android:title="@string/prefs_wxp_longsit_switch" />
</PreferenceScreen>
</PreferenceCategory>
<PreferenceCategory
android:key="pref_category_watchxplus_calibration"
android:title="@string/pref_header_wxp_calibration">
<EditTextPreference
android:defaultValue="200"
android:key="watchxplus_altitude"
android:title="@string/pref_wxp_title_altitude"/>
<PreferenceScreen
android:key="wxp_bp_calibration"
android:title="@string/wxp_bp_calibration_prefs">
<EditTextPreference
android:inputType="number"
android:key="wxp_bp_calibration_low"
android:defaultValue="80"
android:title="@string/pref_wxp_bp_calibration_low"
android:summary="@string/pref_rtl_max_line_length_summary"/>
<EditTextPreference
android:inputType="number"
android:key="wxp_bp_calibration_high"
android:defaultValue="130"
android:title="@string/pref_wxp_bp_calibration_high"
android:summary="@string/pref_rtl_max_line_length_summary"/>
<ListPreference
android:defaultValue="1"
android:title="@string/prefs_wxp_button_bp_calibration"
android:entries="@array/wxp_bp_cal"
android:entryValues="@array/wxp_bp_cal_values"
android:key="wxp_button_BP_calibration_list"
android:summary="@string/prefs_wxp_button_bp_calibration_sum" />
</PreferenceScreen>
</PreferenceCategory>
<!--
<PreferenceCategory
android:key="pref_category_watchxplus_test"
android:title="Test new commands"
android:summary="!!!Warning!!!">
<EditTextPreference
android:inputType="number"
android:key="wxp_newcmd_first"
android:defaultValue="5"
android:title="first byte (dec)"
android:summary="%s"/>
<EditTextPreference
android:inputType="number"
android:key="wxp_newcmd_second"
android:defaultValue="5"
android:title="second byte (dec)"
android:summary="%s"/>
</PreferenceCategory>
-->
</PreferenceScreen>
android:title="@string/preferences_watchxplus_settings"/>
</PreferenceCategory>

View File

@ -0,0 +1,128 @@
<?xml version="1.0" encoding="utf-8"?>
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<PreferenceCategory
android:key="pref_category_watchxplus_notification"
android:title="@string/pref_header_wxp_call_notification">
<PreferenceScreen
android:key="pref_category_watchxplus_ringing"
android:title="@string/pref_header_wxp_notification_call">
<PreferenceCategory
android:title="@string/pref_header_wxp_notification_call"/>
<EditTextPreference
android:defaultValue="0"
android:key="watchxplus_repeat"
android:summary="@string/pref_wxp_title_repeat_on_call_summary"
android:title="@string/pref_wxp_title_repeat_on_call"/>
<CheckBoxPreference
android:layout="@layout/preference_checkbox"
android:defaultValue="false"
android:key="watchxplus_continious"
android:title="@string/prefs_wxp_continious" />
</PreferenceScreen>
<PreferenceScreen
android:key="pref_category_watchxplus_miss"
android:title="@string/pref_header_wxp_notification_misscall">
<PreferenceCategory
android:title="@string/pref_header_wxp_notification_misscall"/>
<EditTextPreference
android:defaultValue="0"
android:key="watchxplus_repeat_missedcall"
android:summary="@string/pref_wxp_title_repeat_on_misscall_summary"
android:title="@string/pref_wxp_title_repeat_on_misscall"/>
<CheckBoxPreference
android:layout="@layout/preference_checkbox"
android:defaultValue="false"
android:key="watchxplus_missed"
android:title="@string/prefs_wxp_missed" />
</PreferenceScreen>
<PreferenceScreen
android:key="pref_category_watchxplus_callhandling"
android:title="@string/pref_header_wxp_notification_callhandling">
<PreferenceCategory
android:title="@string/pref_header_wxp_longsit"/>
<CheckBoxPreference
android:layout="@layout/preference_checkbox"
android:defaultValue="false"
android:key="watchxplus_button_reject"
android:summary="@string/pref_wxp_title_reject_summary"
android:title="@string/prefs_wxp_reject" />
<CheckBoxPreference
android:layout="@layout/preference_checkbox"
android:defaultValue="false"
android:key="watchxplus_shake_reject"
android:summary="@string/pref_wxp_title_shake_reject_summary"
android:title="@string/prefs_wxp_shake_reject" />
</PreferenceScreen>
</PreferenceCategory>
<PreferenceCategory
android:key="pref_category_watchxplus_settings"
android:title="@string/pref_header_wxp_settings">
<ListPreference
android:defaultValue="0"
android:title="@string/wxp_power_mode_title"
android:entries="@array/wxp_mode"
android:entryValues="@array/wxp_mode_values"
android:key="pref_wxp_power_mode"
android:summary="%s" />
<ListPreference
android:defaultValue="1"
android:title="@string/pref_title_language"
android:entries="@array/wxp_language"
android:entryValues="@array/wxp_language_values"
android:key="pref_wxp_language"
android:summary="%s" />
<PreferenceScreen
android:key="pref_category_watchxplus_longsit_settings"
android:title="@string/pref_header_wxp_longsit">
<PreferenceCategory
android:title="@string/pref_header_wxp_longsit"/>
<EditTextPreference
android:defaultValue="60"
android:key="pref_watchxplus_longsit_period"
android:summary="@string/pref_wxp_longsit_period_summary"
android:title="@string/pref_wxp_title_longsit"/>
<CheckBoxPreference
android:layout="@layout/preference_checkbox"
android:defaultValue="false"
android:key="pref_watchxplus_longsit_switch"
android:summary="@string/pref_wxp_longsit_switch_summary"
android:title="@string/prefs_wxp_longsit_switch" />
</PreferenceScreen>
</PreferenceCategory>
<PreferenceCategory
android:key="pref_category_watchxplus_calibration"
android:title="@string/pref_header_wxp_calibration">
<EditTextPreference
android:defaultValue="200"
android:key="pref_watchxplus_altitude"
android:title="@string/pref_wxp_title_altitude"/>
<PreferenceScreen
android:key="wxp_bp_calibration"
android:title="@string/wxp_bp_calibration_prefs">
<PreferenceCategory
android:title="@string/wxp_bp_calibration_prefs"/>
<EditTextPreference
android:inputType="number"
android:key="pref_wxp_bp_calibration_low"
android:defaultValue="80"
android:title="@string/pref_wxp_bp_calibration_low"
android:summary="@string/pref_rtl_max_line_length_summary"/>
<EditTextPreference
android:inputType="number"
android:key="pref_wxp_bp_calibration_high"
android:defaultValue="130"
android:title="@string/pref_wxp_bp_calibration_high"
android:summary="@string/pref_rtl_max_line_length_summary"/>
<ListPreference
android:defaultValue="1"
android:title="@string/prefs_wxp_button_bp_calibration"
android:entries="@array/wxp_bp_cal"
android:entryValues="@array/wxp_bp_cal_values"
android:key="wxp_button_BP_calibration_list"
android:summary="@string/prefs_wxp_button_bp_calibration_sum" />
</PreferenceScreen>
</PreferenceCategory>
</PreferenceScreen>