fix(bedtime): DST-safe windows, ordered edits, quieter passes

Whether the wake time is the same night or the next morning is now
decided on the local times, so a bedtime in a spring-forward gap no
longer turns a 45-minute window into a day-long one. Screen edits start
undispatched so they reach the engine's lock in the order they were made,
and an edit that rewrites the rule also re-asserts the mode, in case the
platform reset its state.

The launch-time bedtime pass runs even if an earlier engine pass failed,
a restore that never applied settings no longer forces the mode, and a
user who never turned bedtime on pays nothing for it at launch or boot.
The screen says when equal bedtime and wake-up times mean it never starts.

Refs #1
This commit is contained in:
makiolaj committed 2026-10-22 11:53:39 +02:00
1 parent 2dce78281a
commit 1a443c066f
11 files changed
+87 -38

No files matched your search

+1
View File
@@ -448,6 +448,7 @@
<string name="bedtime_enabled">Bedtime mode</string>
<string name="bedtime_enabled_on">On, %1$s to %2$s</string>
<string name="bedtime_enabled_off">Off</string>
<string name="bedtime_enabled_same_time">Bedtime and wake-up are the same time, so it never starts</string>
<string name="bedtime_access_title">Allow Do Not Disturb access</string>
<string name="bedtime_access_summary">Clockula needs it to turn its bedtime mode on and off. Find Clockula in the list and allow it. Without it, only the reminder works.</string>
<string name="bedtime_access_allow">Allow</string>