Skip to content

feat(ui): add layout toggle button, detailed list view, and Android Auto content style sync - #1055

Open
mniedling wants to merge 1 commit into
FoedusProgramme:betafrom
mniedling:feature/layout-views
Open

mniedling wants to merge 1 commit into
FoedusProgramme:betafrom
mniedling:feature/layout-views

Conversation

@mniedling

Copy link
Copy Markdown

Hi, here is another idea to enhance the app with a few useful features.

Summary

This PR introduces several UI enhancements and Android Auto content style synchronizations:

  1. Header Layout Toggle Button:

    • Added a dedicated layout switch button in list headers to cycle between Compact List ➔ List (Detailed) ➔ Compact Grid ➔ Grid.
    • Layout choices persist per category across sessions in SharedPreferences ("L" + adapterType).
  2. Detailed List View:

    • Preserves standard 50dp cover size while showing an informative third row.
    • Displays file date added/saved, duration, and a favorite heart indicator (❤️) for favorited tracks.
    • Shows relevant metadata (date added, year, song count) for Albums and Playlists.
  3. Android Auto Content Style Synchronization:

    • LibraryTreeLoader now dynamically synchronizes categories (Songs, Albums, Artists, Playlists, Genres, Dates, Folders) with the user's chosen view preference via MediaConstants content style hints (EXTRAS_VALUE_CONTENT_STYLE_GRID_ITEM vs EXTRAS_VALUE_CONTENT_STYLE_LIST_ITEM).
    • Real-time updates in Android Auto via notifyChildrenChanged when toggling layout on the phone.
    • Provided fallback artwork URIs for Genres, Dates, and Folders so Android Auto can reliably display them as grid tiles.

Verification

  • Verified on phone and on real vehicle hardware with Android Auto.

Kind regards

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