Keep phone skip controls when no car is bound #56

Merged
alexander merged 14 commits from mcp/issue-38-phone-skip-layout into main 2026-09-19 10:12:38 +02:00
Owner

Closes #38

Ownership

Android System & Auto Agent — media-session/system-control surface only.

What changed

  • make media-button priority follow actual CarConnections.isConnected() state;
  • no car bound: skip back/forward take the compact primary slots;
  • car bound: Car/Headset take those slots when available;
  • keep displaced actions available through their overflow fallback;
  • include car-binding state in the publication key so first bind/final unbind republish even when OutputButtons itself is unchanged;
  • suppress repeated publication while the binding/output state is unchanged.

Safety

SLOT_BACK remains occupied in every tested car-bound/action-visibility combination, preventing raw Previous from becoming exposed to the single-window player.

Automated proof

  • MediaButtonLayoutTest: both car states and output visibility matrix through Media3's real legacy slot conversion;
  • MediaButtonSlotConversionTest: both binding states, skip relocation and SLOT_BACK invariant;
  • MediaButtonPublishingTest: first bind/final unbind publication and no repeated-state republish storm.

Acceptance still requiring hardware/DHU

  • phone notification shows compact skip back/forward with no car bound;
  • Android Auto shows Car/Headset in the primary positions while bound;
  • repeated connect/disconnect switches layout without interrupting playback.

No #6 behavior changes are included; that issue will be re-tested only after this PR is reviewed and merged.

Closes #38 ## Ownership Android System & Auto Agent — media-session/system-control surface only. ## What changed - make media-button priority follow actual `CarConnections.isConnected()` state; - no car bound: skip back/forward take the compact primary slots; - car bound: Car/Headset take those slots when available; - keep displaced actions available through their overflow fallback; - include car-binding state in the publication key so first bind/final unbind republish even when `OutputButtons` itself is unchanged; - suppress repeated publication while the binding/output state is unchanged. ## Safety `SLOT_BACK` remains occupied in every tested car-bound/action-visibility combination, preventing raw Previous from becoming exposed to the single-window player. ## Automated proof - `MediaButtonLayoutTest`: both car states and output visibility matrix through Media3's real legacy slot conversion; - `MediaButtonSlotConversionTest`: both binding states, skip relocation and SLOT_BACK invariant; - `MediaButtonPublishingTest`: first bind/final unbind publication and no repeated-state republish storm. ## Acceptance still requiring hardware/DHU - phone notification shows compact skip back/forward with no car bound; - Android Auto shows Car/Headset in the primary positions while bound; - repeated connect/disconnect switches layout without interrupting playback. No #6 behavior changes are included; that issue will be re-tested only after this PR is reviewed and merged.
Author
Owner

Final implementation-owner status

  • Exact head: 06e221e299090f518fa8c960f3b3d26d1f5df789
  • Forgejo Actions: success, pull-request workflow run #88 (run id 90)
  • Full verifyDebug: BUILD SUCCESSFUL
  • PR remains mergeable; not merged.

Automated coverage verifies car bound/unbound layout priority, output-action visibility combinations, Media3 slot conversion, the permanent SLOT_BACK invariant, and meaningful-state publication without repeated-state republish storms.

Outstanding device/DHU acceptance:

  1. With no car controller bound, confirm the phone notification compact controls show skip back + skip forward.
  2. Bind Android Auto and confirm Car + Headset take the primary slots when available and skips remain reachable in overflow.
  3. Disconnect Android Auto and confirm the phone returns to compact skips without interrupting playback.
  4. Repeat connect/disconnect several times and confirm no flicker/republication loop or playback interruption.

Per lane sequencing, issue #6 has not been changed or re-tested as merged behavior yet. Stop here until #38 is reviewed and merged.

Final implementation-owner status - Exact head: `06e221e299090f518fa8c960f3b3d26d1f5df789` - Forgejo Actions: **success**, pull-request workflow run #88 (run id 90) - Full `verifyDebug`: **BUILD SUCCESSFUL** - PR remains mergeable; not merged. Automated coverage verifies car bound/unbound layout priority, output-action visibility combinations, Media3 slot conversion, the permanent `SLOT_BACK` invariant, and meaningful-state publication without repeated-state republish storms. Outstanding device/DHU acceptance: 1. With no car controller bound, confirm the phone notification compact controls show skip back + skip forward. 2. Bind Android Auto and confirm Car + Headset take the primary slots when available and skips remain reachable in overflow. 3. Disconnect Android Auto and confirm the phone returns to compact skips without interrupting playback. 4. Repeat connect/disconnect several times and confirm no flicker/republication loop or playback interruption. Per lane sequencing, issue #6 has **not** been changed or re-tested as merged behavior yet. Stop here until #38 is reviewed and merged.
alexander force-pushed mcp/issue-38-phone-skip-layout from 06e221e299 to cec2f3c8b4 2026-09-19 10:05:49 +02:00 Compare
alexander deleted branch mcp/issue-38-phone-skip-layout 2026-09-19 10:12:38 +02:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
alexander/Audiobookshelf-Manager-Claude!56
No description provided.