Skip to content

feat: add Chapter Menu and Chapter Marks - #9

Open
paviro wants to merge 6 commits into
RepriseOS:mainfrom
paviro:feature/chapters
Open

paviro wants to merge 6 commits into
RepriseOS:mainfrom
paviro:feature/chapters

Conversation

@paviro

@paviro paviro commented Nov 27, 2026 •

Copy link
Copy Markdown
Contributor

Merge after #6 and RepriseOS/repriseos#100.
Own commits: paviro/extensions@feature/media-fixes...feature/chapters (the rest of the diff is #6).

Ported from RevolaOS.

  • chapter-menu: a Chapters row in the context menu of a podcast or iTunes U episode and in the Now Playing context menu, when the item has chapters. It lists each chapter's title and start time. Choosing one seeks there from Now Playing, or plays the episode from there from an episode list.
  • chapter-marks: the Now Playing progress bar leaves out the chapter marks once they would average under 3 px each, about 55 chapters.

Chapter Menu needs RepriseOS/repriseos#100 to open its screen from the context menu. The manifests ask for API 1.82, which #100 does not change, so the release tags wait for a RepriseOS release that includes it. The catalog icons are Cupertino Icons glyphs (MIT).

Tested in the emulator.

Screenshots

01-chapter-list 02-marks-stock 03-marks-hidden

paviro and others added 6 commits November 27, 2026 15:03
The catalog test required a first screenshot for every extension that is
not a library. An extension without a screen has nothing to show, so the
test now checks the alt text and width of each screenshot a listing has.
Apple's MP4 parser compares the 64-bit decode time with the edit list after
sign-extending its low word, so an AAC or Apple Lossless file with an edit
list ends at 2^31 media ticks: 13:31:35 at 44.1 kHz. The extension binds the
three compare words with loads of the high word. Disabling it restores
Apple's compares.

From RevolaOS extensions c179e6dc21ea. The same fix as RepriseOS pull
request 62 by kayboll, arrived at independently.

Co-authored-by: kayboll <16205646+kayboll@users.noreply.github.com>
Apple's MP4 parser seeks an AAC or Apple Lossless file by stepping through
every sample up to the target, from the first sample for a backward seek.
A jump of several hours in an audiobook takes seconds and many disk reads.
The extension filters the entry of the sample walk, finds the chunk holding
the target from the in-memory time-to-sample and sample-to-chunk tables and
starts Apple's walk at that chunk's first sample. Files with more than one
edit or more than one frame length before the target seek the stock way.

From RevolaOS extensions c179e6dc21ea. The same approach as RepriseOS pull
request 63 by kayboll, arrived at independently.

Co-authored-by: kayboll <16205646+kayboll@users.noreply.github.com>
Sleep Timer in the Now Playing context menu opens a full-width list of
Apple's sleep timer choices with the active one highlighted; choosing one
sets Apple's timer, the one Extras > Alarms > Sleep Timer sets, and
returns to Now Playing. While it runs, the extension filters the Now
Playing model's shuffle picture and draws the minutes left and a moon
before it.

From RevolaOS extensions c179e6dc21ea. Based on RepriseOS pull request 75
by kayboll, which opens the stock Alarms list instead.

Co-authored-by: kayboll <16205646+kayboll@users.noreply.github.com>
Chapters in the context menu of a podcast or iTunes U episode and in the
Now Playing context menu, shown when the item has chapters. The screen
lists each chapter's title and start time. From Now Playing it opens on
the chapter playing and choosing one seeks the track there; from an
episode list it opens on the first chapter and choosing one plays the
episode from there, as choosing an audiobook chapter does. Chapters with
an empty title read "Chapter N". If the track changed or the library
reloaded while the list was open, choosing a chapter does nothing.

From RevolaOS extensions 72562b52fe7e.
Filters the Now Playing progress bar's marker draw and leaves every
chapter mark off once the marks would average under 3 px each, about 55
chapters on the classic's bar. Tracks with fewer chapters keep the stock
marks.

From RevolaOS extensions 72562b52fe7e.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant