refactor(settings): remove the unused default timer duration
Settings > Timers offered a "Default duration", but nothing that creates a timer ever read it: the keypad starts empty. The row, its preference, ClockDefaults.timerDuration and the backup field are gone, and the screen's hint and the hub's subtitle now only speak of the sound. Backups no longer write default_timer_duration_millis. Older files that carry it still import, since the codec ignores unknown keys. Closes #5
This commit is contained in:
+5
-3
@@ -33,7 +33,7 @@ written here.
|
||||
defines — `format`, `version`, an alarm's `hour`/`minute`, a world clock's
|
||||
`zone_id`, a timer's `duration_millis` — rejects the **whole file** with a
|
||||
specific reason. Nothing is imported half-way.
|
||||
- Settings values (snooze minutes, volume ramp, timer duration, …) are
|
||||
- Settings values (snooze minutes, volume ramp, …) are
|
||||
**not** range-checked at parse time; they pass through the same clamps
|
||||
`ClockPrefs`/`SettingsPrefs` already apply on every write, so a value from
|
||||
a future, more permissive version degrades to the nearest valid one instead
|
||||
@@ -118,13 +118,15 @@ device or after a reboot (`docs/PLAN.md` §5). Every imported timer lands
|
||||
"default_alarm_ringtone_uri": null,
|
||||
"default_timer_ringtone_uri": null,
|
||||
"default_dismiss_challenge": "NONE",
|
||||
"default_timer_duration_millis": 300000,
|
||||
"home_zone_id": null,
|
||||
"timer_presets": [60000, 120000, 180000, 300000, 600000, 900000, 1800000, 3600000]
|
||||
}
|
||||
```
|
||||
|
||||
Field names mirror `ClockPrefs`'/`SettingsPrefs`' own on-disk keys. Every
|
||||
Field names mirror `ClockPrefs`'/`SettingsPrefs`' own on-disk keys. Older
|
||||
files may also carry `default_timer_duration_millis`, from a default timer
|
||||
length setting that has since been removed; it is ignored on import like any
|
||||
other unknown field. Every
|
||||
numeric/duration value is clamped on *apply*, through the existing pref
|
||||
setters — never on parse.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user