Skip to content

The track menu and source list on forms (Settings form migration 5/5) - #339

Merged
GLinnik21 merged 1 commit into
mainfrom
settings-form-5
Oct 1, 2026
Merged

GLinnik21 merged 1 commit into
mainfrom
settings-form-5

Conversation

@GLinnik21

@GLinnik21 GLinnik21 commented Oct 1, 2026 •

Copy link
Copy Markdown
Collaborator

Settings form migration 5/5, the last one (design: docs/settings-form.md, now marked complete). The track menu and the source list are now declared forms. With this, no menu dispatches through a vector kept alongside its rows.

Rebased onto main after #336 (4/5) merged, resolving the overlap with #335 by hand: ui/track_menu.rs keeps #335's measure-aware panel_h/fit_notes through form.table; Form::map carries #335's skipped; new Binding literals carry disabled. Re-gated after the rebase: make check 5309/5383/102 passed, 0 failed; replay 0 failures; harness 366 OK. Sim: rebased vs main track menus are pixel-identical in the popover (audio differs only in the playing video behind the glass).

What changes

  • Track menu: TrackRow is the row identity, and notes and separators are inert slots. Deleted: TrackMenuState.targets / .audio_targets, AudioRowTarget, RowTarget::Note, table_sections, lock_style_rows, insert_row_at and sel_for_targets.
  • Source list: SrcTarget is the row identity. Deleted: SrcAction, source_list::sections() / sel, OnboardScreen.acts, and AltSourcesScreen's action_at / section_for and its separate table.
  • Library menu: it is now a FormTable<String, Action, Infallible>, keeping its identity interner so keys stay stable across a reorder. LibraryMenu.rows and MenuDraft.rows / sections are deleted.
  • family::table_focus: deleted; it had no caller left.
  • Form: gains contains, slots and map, each with tests.
  • Tests:
    • New: a track-menu reorder test (no focus key moves), a test that the separator before Recheck is inert and Recheck is the last focusable row, and form_tests for the new helpers.
    • Existing tests are converted to address rows by Id or key.

State shape

Canon is unchanged and there is no SCREEN_SHAPES_PIN bump. The replay fixtures are unchanged.

Verification (on the committed tree)

  • make check: test result: ok. 5287 passed; 0 failed, ok. 5361 passed; 0 failed, ok. 102 passed; 0 failed
  • --no-default-features check is clean; RELEASE=1 make is clean.
  • make check-replay: 3 fixtures, 6 replays, 0 failures
  • tests.test_harness: Ran 366 tests, OK
  • Simulator before/after with mock PMS (--extra-media, 2 audio and 2 subtitle streams, guest):
    • Audio tab: 0 differing pixels in the popover rect.
    • Subtitles tab: 0 differing pixels in the popover rect.
    • Source-list editor: identical apart from the dev fps counter.

🤖 Generated with Claude Code

@GLinnik21
GLinnik21 force-pushed the settings-form-4 branch 2 times, most recently from 0ffda05 to 1b58afc Compare October 1, 2026 01:11
Base automatically changed from settings-form-4 to main October 1, 2026 01:36
The track menu (Audio and Subtitles tabs) and the source list move onto
ui::form Form/FormTable. Notes and separators are inert slots: a layout index,
no id, key or action, never focusable. Deleted: TrackMenuState targets /
audio_targets and AudioRowTarget / RowTarget::Note, source_list's SrcAction and
sections(), the onboarding editor's acts vector, alt_sources' action_at and the
Library menu's MenuRow rows. Every table-backed menu now resolves focus and
activation by identity (TrackRow, SrcTarget, AltId, the Library menu's interned
identity string).

Form gains contains / slots / map (a shared builder serves a surface with its own
identities). family::table_focus is deleted; docs/settings-form.md records the
migration as complete. Adds a track-menu reorder test.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
@GLinnik21
GLinnik21 merged commit 1004c69 into main Oct 1, 2026
5 checks passed
@GLinnik21
GLinnik21 deleted the settings-form-5 branch October 1, 2026 02:35
GLinnik21 added a commit that referenced this pull request Oct 1, 2026
…the track-menu form (#345)

The Subtitles tab's Color row becomes a Style row that pushes a page stack on #339's
`TrackRow` form: Style -> Size / Position / Color pickers, each a drill-in showing its
current value, with a title band (click pops), a saved return id and scroll per page,
and `FormTable::refresh_with` so a live refresh keeps focus by id.

- Size and Position persist optimistically (`route::select_subtitle_size/position`
  publish the live atomic, then a persist-only storage write; never republished);
  Settings' pickers use the same path and a retry on the checked row is only a no-op
  when the stored value matches too.
- Style follows Timing's availability; image and ASS subtitles dim Size and Position
  with their own notes while Color stays live.
- `SubSig` rebuilds a sub-page in place and pops to root only when its availability
  changes.
- The player overlay's replay canon carries the tab, page path and saved return ids:
  `SCREEN_SHAPES_PIN` moves and the three replay fixtures are re-recorded.
- `PLAYER_MENU_MIN_W` / `TableView::min_panel_w` give Tracks and More a 440 floor.
- Five new strings in en/es/be with fit tests.

Co-authored-by: Claude Sonnet 5.5 <[email protected]>
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