forked from upstream-mirrors/OpenTracks
@@ -14,11 +14,7 @@ final class PreferenceHelper {
|
||||
for (int i = 0; i < entryValues.length; i++) {
|
||||
int value = Integer.parseInt(entryValues[i]);
|
||||
|
||||
if (value == PreferencesUtils.getMinRecordingIntervalAdaptAccuracy(context)) {
|
||||
entries[i] = context.getString(R.string.value_adapt_accuracy);
|
||||
} else if (value == PreferencesUtils.getMinRecordingIntervalAdaptBatteryLife(context)) {
|
||||
entries[i] = context.getString(R.string.value_adapt_battery_life);
|
||||
} else if (value == PreferencesUtils.getMinRecordingIntervalDefault(context)) {
|
||||
if (value == PreferencesUtils.getMinRecordingIntervalDefault(context).getSeconds()) {
|
||||
entries[i] = context.getString(R.string.value_smallest_recommended);
|
||||
} else {
|
||||
entries[i] = value < 60 ? context.getString(R.string.value_integer_second, value) : context.getString(R.string.value_integer_minute, value / 60);
|
||||
|
||||
@@ -203,7 +203,7 @@ public class SettingsActivity extends AbstractActivity implements ChooseActivity
|
||||
findPreference(getString(R.string.min_recording_interval_key))
|
||||
.setSummaryProvider(
|
||||
preference -> {
|
||||
Duration interval = Duration.ofSeconds(PreferencesUtils.getMinRecordingInterval(sharedPreferences, getContext()));
|
||||
Duration interval = PreferencesUtils.getMinRecordingInterval(sharedPreferences, getContext());
|
||||
return getString(R.string.settings_recording_location_frequency_summary, getString(R.string.value_integer_second, interval.getSeconds()));
|
||||
}
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user