Schedule pages and rotation rules can be skipped in slow mode

Each page in a schedule block, and each rule that adds its page to the
rotation, has a "skip in slow mode" checkbox. While slow mode is on those
pages are left out of the rotation; when none of the block's pages are
left, the chosen page is shown. The rotation keeps its own timers.

Schedule format version 5; version 4 is converted when read and stored
again in version 5 on the next save.

Version 2.18.0.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
mangavalkandClaude Opus 5.5 committed 2026-10-20 21:14:14 +02:00
1 parent a91d2550d7
commit e9f3c16c78
13 files changed
+177 -13

No files matched your search

+4 -3
View File
@@ -131,15 +131,16 @@ PageChoice PageSelector::update(int minute, uint32_t now)
const ScheduleBlock &b = _schedule->blocks[_block];
effect = b.effect;
for (int i = 0; i < b.item_count; i++)
items[count++] = {b.items[i].page, b.items[i].seconds * 1000UL, ShowReason::Schedule, -1};
if (!_slow || !b.items[i].skip_slow_mode)
items[count++] = {b.items[i].page, b.items[i].seconds * 1000UL, ShowReason::Schedule, -1};
}
else
if (count == 0) // no schedule, a manual pick, or slow mode skips all the block's pages
items[count++] = {_chosen, CHOSEN_PAGE_SECONDS * 1000UL, ShowReason::Chosen, -1};
for (int i = 0; i < rule_count; i++)
{
const TriggerRule &r = _schedule->rules[i];
if (r.mode == TriggerMode::AddToRotation && _rule_active[i] && ruleInBlock(r, _block) &&
(r.over_manual || !_picked))
(r.over_manual || !_picked) && (!_slow || !r.skip_slow_mode))
items[count++] = {r.page, r.seconds * 1000UL, ShowReason::Rotation, i};
}